﻿using System;
using System.Linq;
using System.Web;
using System.Web.Services;
using System.Web.Services.Protocols;
using System.Xml.Linq;
using System.Data.OracleClient;
using System.EnterpriseServices;
using PGun.Core;
using System.IO;
using System.Data;
using System.IO.Compression;
using System.Runtime.Serialization.Formatters.Binary;

/// <summary>
/// 2011.11.02 박승한 - EMDISBEST 웹서비스(압축적용)
/// </summary>
[WebService(Namespace = "http://EMDISBEST.co.kr/")]
[WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)]
// ASP.NET AJAX를 사용하여 스크립트에서 이 웹 서비스를 호출하려면 다음 줄의 주석 처리를 제거합니다. 
// [System.Web.Script.Services.ScriptService]
public class Service_Compression : System.Web.Services.WebService {

    public Service_Compression () {

        //디자인된 구성 요소를 사용하는 경우 다음 줄의 주석 처리를 제거합니다. 
        //InitializeComponent(); 
    }


    #region == 로그인 INT 결과 반환 ==

    /// <summary>
    /// 로그인
    /// </summary>
    /// <param name="pjumin"></param>
    /// <param name="ppass"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "로그인(pJmin,pPassword)")]
    public int Select_W_LOGIN_P1(string pJmin, string pPassword)
    {
        int nReturn = 2; //기본 실패
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_JUMIN_NO", pJmin, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_PASSWORD", pPassword, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_W_LOGIN_P", oIDataParameter);
            }

            if (dsReturn != null && dsReturn.Tables[0].Rows.Count > 0)
            { 
                int.TryParse(dsReturn.Tables[0].Rows[0][0].ToString(),out nReturn);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return nReturn;
    }
    #endregion

    #region == 로그인 로그인 정보 Dataset 반환 ==

    /// <summary>
    /// 로그인
    /// </summary>
    /// <param name="pjumin"></param>
    /// <param name="ppass"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "로그인(pJmin,pPassword)")]
    public string Select_W_LOGIN_P2(string pJmin, string pPassword)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_JUMIN_NO", pJmin, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_PASSWORD", pPassword, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_W_LOGIN_P", oIDataParameter);
            }

        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }
    #endregion


    #region == 주민번호로 프로젝트 목록 조회 ==

    /// <summary>
    /// 주민번호로 프로젝트 목록 조회
    /// </summary>
    /// <param name="pjumin"></param>
    /// <param name="ppass"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "주민번호로 프로젝트 목록 조회(pJmin)")]
    public string Select_W_SELPROJ_BY_JUMIN_S(string pJmin)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[2];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_JUMIN_NO", pJmin, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_W_SELPROJ_BY_JUMIN_S", oIDataParameter);
            }

        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }
    #endregion

    #region == 노드아이디로 프로젝트 목록 조회 ==

    /// <summary>
    /// 노드아이디로 프로젝트 목록 조회
    /// </summary>
    /// <param name="pjumin"></param>
    /// <param name="ppass"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = " 노드아이디로 프로젝트 목록 조회(string pJmin,int pLevel,string pYear,string pProjClass,string pProjType)")]
    public string Select_W_SELPROJ_BY_NODE_S(string pJmin,int pLevel,string pYear,string pProjClass,string pProjType)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[6];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_JUMIN_NO", pJmin, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_LEVEL", pLevel, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_YEAR", pYear, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_PROJ_CLASS", pProjClass, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_PROJ_TYPE", pProjType, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_W_SELPROJ_BY_NODE_S", oIDataParameter);
            }

        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }
    #endregion


    #region == 계약확정이 체크되었는지 여부 반환 ==
    /// <summary>
    /// 작업정보 조회
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "계약확정이 체크되었는지 여부 반환(PROJ_CD)")]
    public string Select_PROJ_CONTRACT_YN_S(string pAS_PROJ_CD, string pDt)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pAS_PROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", pDt, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_PROJ_CONTRACT_YN_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }


        return this.CompressDataSet(dsReturn);
    }
    #endregion


    #region == 공사일지 등록(프로젝트 최초) INSERT(Procedure : SP_PROJ_NEW1_DAY_I ) ==

    /// <summary>
    /// 공사일지 등록(프로젝트 최초) INSERT(Procedure : SP_PROJ_NEW1_DAY_I )
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 공사일지 등록(프로젝트 최초) INSERT(Procedure : SP_PROJ_NEW1_DAY_I )")]
    public int INSERT_PROJ_NEW1_DAY_I(string pAS_PROJ_CD, string pAS_DT, string pDegree)
    {
        int nResult = 0;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pAS_PROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", pAS_DT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_DEGREE", pDegree, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_PROJ_NEW1_DAY_I", oIDataParameter);
            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }

    #endregion

    #region == 공사일지 등록 (새로운 날짜) INSERT(Procedure : SP_PROJ_NEW2_DAY_I ) ==

    /// <summary>
    ///공사일지 등록 (새로운 날짜) INSERT(Procedure : SP_PROJ_NEW2_DAY_I )
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 공사일지 등록 (새로운 날짜) INSERT(Procedure : SP_PROJ_NEW2_DAY_I )")]
    public int INSERT_PROJ_NEW2_DAY_I(string pAS_PROJ_CD, string pAS_DT)
    {
        int nResult = 0;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[2];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pAS_PROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", pAS_DT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_PROJ_NEW2_DAY_I", oIDataParameter);
            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }

    #endregion

    #region == 공사일지 삭제  DELETE(Procedure : SP_PROJ_DAY_D ) ==

    /// <summary>
    ///공사일지 삭제  DELETE(Procedure : SP_PROJ_DAY_D )
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 공사일지 삭제  DELETE(Procedure : SP_PROJ_DAY_D )")]
    public int DELETE_PROJ_DAY_D(string pAS_PROJ_CD, string pAS_DT)
    {
        int nResult = 0;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[2];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pAS_PROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", pAS_DT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_PROJ_DAY_D", oIDataParameter);
            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }

    #endregion


    #region == 그리드 전체 조회 조회 ==
    /// <summary>
    /// 그리드 전체 조회 조회
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "그리드 전체 조회 조회")]
    public string Select_ALL_GRID_S(string pAS_PROJ_CD, string pAS_DT)
    {
        DataSet dsReturn = null;
        try
        {
            dsReturn = new DataSet();

            DataTable dt01 = new DataTable();
            dt01 = this.Select_FPD220T_P_c(pAS_PROJ_CD, pAS_DT).Tables[0].Copy();
            dt01.TableName = "인원현황";
            dsReturn.Tables.Add(dt01);

            DataTable dt02 = new DataTable("주요자재현황");
            dt02 = this.Select_FPD240T_P_c(pAS_PROJ_CD, pAS_DT).Tables[0].Copy();
            dt02.TableName = "주요자재현황";
            dsReturn.Tables.Add(dt02);

            DataTable dt03 = new DataTable("장비현황");
            dt03 = this.Select_D_FPD230T_S_c(pAS_PROJ_CD, pAS_DT).Tables[0].Copy();
            dt03.TableName = "장비현황";
            dsReturn.Tables.Add(dt03);

            DataSet ds04 = new DataSet("공종계획");
            ds04 = this.Select_D_FPD210T_1_S_c(pAS_PROJ_CD, pAS_DT, "%");
            ds04.Tables[0].TableName = "공종계획1";
            ds04.Tables[1].TableName = "공종계획2";
            dsReturn.Tables.Add(ds04.Tables[0].Copy());
            dsReturn.Tables.Add(ds04.Tables[1].Copy());

            DataTable dt05 = new DataTable("운송현황");
            dt05 = this.Select_DAYTRANSPORT1_S_c(pAS_PROJ_CD, pAS_DT).Tables[0].Copy();
            dt05.TableName = "운송현황";
            dsReturn.Tables.Add(dt05);

            DataTable dt06 = new DataTable("경비현황");
            dt06 = this.Select_D_DAYEATPAY_S_c(pAS_PROJ_CD, pAS_DT).Tables[0].Copy();
            dt06.TableName = "경비현황";
            dsReturn.Tables.Add(dt06);

            DataTable dt07 = new DataTable("지출결의서");
            //dt07 = this.Select_FPD240T_P(pAS_PROJ_CD, pAS_DT).Tables[0].Copy();
            //dt07.TableName = "지출결의서";
            dsReturn.Tables.Add(dt07);

            DataTable dt08 = new DataTable("외주관리");
            dt08 = this.Select_D_FPD370T_S_c(pAS_PROJ_CD, pAS_DT).Tables[0].Copy();
            dt08.TableName = "외주관리";
            dsReturn.Tables.Add(dt08);

            dsReturn.AcceptChanges();

        }
        catch (Exception pException)
        {
           

            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }
    #endregion




    #region == 작업정보 조회 ==
    /// <summary>
    /// 작업정보 조회
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "작업정보 조회(PROJ_CD,DT)")]
    public string Select_D_FPD200T_S(string pAS_PROJ_CD, string pAS_DT)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pAS_PROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", pAS_DT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD200T_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }
    #endregion

    #region == 작업정보 한건 INSERT(Procedure : SP_D_FPD200T_I ) ==

    /// <summary>
    /// 작업정보 INSERT
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 작업정보 한건 INSERT(Procedure : SP_D_FPD200T_I )")]
    public int INSERT_D_FPD200T_I1(string pAS_PROJ_CD, string pAS_DT, string pPROJ_NM, string pREG_NAME, string pCFM_NAME, string pLOC, string pH_TEMP, string pL_TEMP, string pRAINFALL, string pSNOWFALL, string pTO_WORK, string pNE_WORK)
    {
        int nResult = 0;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[12];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pAS_PROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", pAS_DT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_PROJ_NM", pPROJ_NM, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_REG_NAME", pREG_NAME, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_CFM_NAME", pCFM_NAME, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_LOC", pLOC, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_H_TEMP", pH_TEMP, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[7] = oDBManager.GetOraclePrameter("AS_L_TEMP", pL_TEMP, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[8] = oDBManager.GetOraclePrameter("AS_RAINFALL", pRAINFALL, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[9] = oDBManager.GetOraclePrameter("AS_SNOWFALL", pSNOWFALL, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[10] = oDBManager.GetOraclePrameter("AS_TO_WORK", pTO_WORK, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[11] = oDBManager.GetOraclePrameter("AS_NE_WORK", pNE_WORK, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD200T_I", oIDataParameter);
            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }

    #endregion

    #region == 작업정보 다중 INSERT(Procedure : SP_D_FPD200T_I ) ==
    /// <summary>
    /// 작업정보 INSERT
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 작업정보 다중 INSERT(Procedure : SP_D_FPD200T_I )")]
    public int INSERT_D_FPD200T_I2(DataSet pDs)
    {
        int nResult = 0;

        if (pDs == null || pDs.Tables[0].Rows.Count == 0)
            throw new Exception("저장할 데이터가 없습니다.");

        try
        {
            using (DBManager oDBManager = new DBManager())
            {

                foreach (DataRow dr in pDs.Tables[0].Rows)
                {
                    System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[12];
                    oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_PROJ_NM", dr["PROJ_NM"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_REG_NAME", dr["REG_NAME"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_CFM_NAME", dr["CFM_NAME"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_LOC", dr["LOC"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_H_TEMP", dr["H_TEMP"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[7] = oDBManager.GetOraclePrameter("AS_L_TEMP", dr["L_TEMP"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[8] = oDBManager.GetOraclePrameter("AS_RAINFALL", dr["RAINFALL"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[9] = oDBManager.GetOraclePrameter("AS_SNOWFALL", dr["SNOWFALL"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[10] = oDBManager.GetOraclePrameter("AS_TO_WORK", dr["TO_WORK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[11] = oDBManager.GetOraclePrameter("AS_NE_WORK", dr["NE_WORK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    nResult += oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD200T_I", oIDataParameter);

                }
            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }
    #endregion

    #region == 작업정보(AS_PROJ_CD -> DELETE -> INSERT (Procedure :SP_D_FPD200T_D, SP_D_FPD200T_I ) ==

    /// <summary>
    /// 작업정보 INSERT
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 작업정보(AS_PROJ_CD -> DELETE -> INSERT (Procedure :SP_D_FPD200T_D, SP_D_FPD200T_I )")]
    public int REPLACE_D_FPD200T_I3(DataSet pDs)
    {
        int nResult = 0;

        if(pDs == null || pDs.Tables[0].Rows.Count == 0)
            throw new Exception("저장할 데이터가 없습니다.");

        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                //delete
                string strPROJ_CD = pDs.Tables[0].Rows[0]["PROJ_CD"].ToString();

                System.Data.OracleClient.OracleParameter[] oIDataParameterD = new OracleParameter[3];
                oIDataParameterD[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", strPROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameterD[1] = oDBManager.GetOraclePrameter("AS_DT", string.Empty, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameterD[2] = oDBManager.GetOraclePrameter("AS_PROJ_ALL", "Y", System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);

                nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD200T_D", oIDataParameterD);

                foreach (DataRow dr in pDs.Tables[0].Rows)
                {
                    System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[12];
                    oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_PROJ_NM", dr["PROJ_NM"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_REG_NAME", dr["REG_NAME"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_CFM_NAME", dr["CFM_NAME"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_LOC", dr["LOC"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_H_TEMP", dr["H_TEMP"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[7] = oDBManager.GetOraclePrameter("AS_L_TEMP", dr["L_TEMP"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[8] = oDBManager.GetOraclePrameter("AS_RAINFALL", dr["RAINFALL"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[9] = oDBManager.GetOraclePrameter("AS_SNOWFALL", dr["SNOWFALL"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[10] = oDBManager.GetOraclePrameter("AS_TO_WORK", dr["TO_WORK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[11] = oDBManager.GetOraclePrameter("AS_NE_WORK", dr["NE_WORK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    nResult += oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD200T_I", oIDataParameter);

                }
            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }

    #endregion

    #region == 작업정보 한건 UPDATE(Procedure : SP_D_FPD200T_S ) ==

    /// <summary>
    /// 작업정보 UPDATE
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 작업정보 한건 UPDATE(Procedure : SP_D_FPD200T_S )")]
    public int UPDATE_D_FPD200T_U1(string pAS_PROJ_CD, string pAS_DT, string pPROJ_NM, string pREG_NAME, string pCFM_NAME, string pLOC, string pH_TEMP, string pL_TEMP, string pRAINFALL, string pSNOWFALL, string pTO_WORK, string pNE_WORK)
    {
        int nResult = 0;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[12];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pAS_PROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", pAS_DT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_PROJ_NM", pPROJ_NM, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_REG_NAME", pREG_NAME, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_CFM_NAME", pCFM_NAME, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_LOC", pLOC, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_H_TEMP", pH_TEMP, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[7] = oDBManager.GetOraclePrameter("AS_L_TEMP", pL_TEMP, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[8] = oDBManager.GetOraclePrameter("AS_RAINFALL", pRAINFALL, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[9] = oDBManager.GetOraclePrameter("AS_SNOWFALL", pSNOWFALL, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[10] = oDBManager.GetOraclePrameter("AS_TO_WORK", pTO_WORK, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[11] = oDBManager.GetOraclePrameter("AS_NE_WORK", pNE_WORK, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD200T_U", oIDataParameter);
            }
            
        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }
    #endregion

    #region == 작업정보 다중 UPDATE(Procedure : SP_D_FPD200T_U ) ==

    /// <summary>
    /// 작업정보 UPDATE
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 작업정보 다중 UPDATE(Procedure : SP_D_FPD200T_U )")]
    public int UPDATE_D_FPD200T_U2(DataSet pDs)
    {
        int nResult = 0;

        if (pDs == null || pDs.Tables[0].Rows.Count == 0)
            throw new Exception("저장할 데이터가 없습니다.");

        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                foreach (DataRow dr in pDs.Tables[0].Rows)
                {
                    System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[12];
                    oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_PROJ_NM", dr["PROJ_NM"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_REG_NAME", dr["REG_NAME"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_CFM_NAME", dr["CFM_NAME"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_LOC", dr["LOC"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_H_TEMP", dr["H_TEMP"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[7] = oDBManager.GetOraclePrameter("AS_L_TEMP", dr["L_TEMP"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[8] = oDBManager.GetOraclePrameter("AS_RAINFALL", dr["RAINFALL"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[9] = oDBManager.GetOraclePrameter("AS_SNOWFALL", dr["SNOWFALL"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[10] = oDBManager.GetOraclePrameter("AS_TO_WORK", dr["TO_WORK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[11] = oDBManager.GetOraclePrameter("AS_NE_WORK", dr["NE_WORK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    nResult += oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD200T_U", oIDataParameter);

                }
            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }

    #endregion

    #region == 작업정보 한건 DELETE(Procedure : SP_D_FPD200T_D ) ==

    /// <summary>
    /// 작업정보 DELETE
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 작업정보 한건 DELETE(Procedure : SP_D_FPD200T_D )")]
    public int DELETE_D_FPD200T_D1(string pAS_PROJ_CD, string pAS_DT)
    {

        int nResult = 0;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[2];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pAS_PROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", pAS_DT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD200T_D", oIDataParameter);
            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }

    #endregion

    #region == 작업정보 다중 DELETE(Procedure : SP_D_FPD200T_D ) ==


    /// <summary>
    /// 작업정보 DELETE
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 작업정보 다중 DELETE(Procedure : SP_D_FPD200T_D )")]
    public int DELETE_D_FPD200T_D2(DataSet pDs)
    {
        int nResult = 0;

        if (pDs == null || pDs.Tables[0].Rows.Count == 0)
            throw new Exception("저장할 데이터가 없습니다.");

        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                foreach (DataRow dr in pDs.Tables[0].Rows)
                {
                    System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[2];
                    oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    nResult += oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD200T_D", oIDataParameter);

                }
            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }

    #endregion



    #region == 콤보전체(PROJ_CD) ==

    /// <summary>
    /// 콤보전체 리스트조회
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "콤보전체 리스트 조회(PROJ_CD)")]
    public string Select_ALL_COMBO_S()
    {
        DataSet dsReturn = null;
        try
        {
            dsReturn = new DataSet();

            DataTable dt02 = new DataTable("업무직종");
            dt02 = this.Select_DDDWCLASS_NM_S_c().Tables[0].Copy();
            dt02.TableName = "업무직종";
            dsReturn.Tables.Add(dt02);

            DataTable dt03 = new DataTable("협력업체");
            dt03 = this.Select_DDDWCLASS_NM_S2_c().Tables[0].Copy();
            dt03.TableName = "협력업체";
            dsReturn.Tables.Add(dt03);

            DataTable dt04 = new DataTable("관련증빙");
            dt04 = this.Select_DDDW_461_S_c().Tables[0].Copy();
            dt04.TableName = "관련증빙";
            dsReturn.Tables.Add(dt04);

            dsReturn.AcceptChanges();

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return this.CompressDataSet(dsReturn);
    }
    #endregion

    #region == 일자마감 리스트 조회(PROJ_CD) ==

    /// <summary>
    /// 일자마감 리스트조회
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "일자마감 리스트 조회(PROJ_CD)")]
    public string Select_D_DAYWRITE_DAY_S(string pAS_PROJ_CD)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[2];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pAS_PROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_DAYWRITE_DAY_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }

        return this.CompressDataSet(dsReturn);
    }
    #endregion

    #region == 업무직종 리스트 조회 ==

    /// <summary>
    /// 업무직종 리스트 조회
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "업무직종 리스트 조회")]
    public string Select_DDDWCLASS_NM_S()
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[1];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_DDDWCLASS_NM_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }

        return this.CompressDataSet(dsReturn);
    }
    #endregion

    #region == 협력업체 리스트 조회 ==

    /// <summary>
    /// 업무직종 리스트 조회
    /// </summary>

    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "협력업체 리스트 조회")]
    public string Select_DDDWCLASS_NM_S2()
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[1];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_DDDWCLASS_NM_S2", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }

        return this.CompressDataSet(dsReturn);
    }
    #endregion

    #region == 관련증빙 리스트 조회 ==

    /// <summary>
    /// 관련증빙 리스트 조회
    /// </summary>

    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "관련증빙 리스트 조회")]
    public string Select_DDDW_461_S()
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[1];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_DDDW_461_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }

        return this.CompressDataSet(dsReturn);
    }
    #endregion

    #region == 일용직 팀명리스트 조회 ==

    /// <summary>
    /// 일용직 팀명리스트 조회
    /// </summary>

    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "일용직 팀명리스트")]
    public string Select_DDDW_GROUPNM_ALL_S()
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[1];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_DDDW_GROUPNM_ALL_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }

        return this.CompressDataSet(dsReturn);
    }
    #endregion


    #region == 일자마감 리스트 조회(PROJ_CD) ==

    /// <summary>
    /// 일자마감 리스트조회
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    private DataSet Select_D_DAYWRITE_DAY_S_c(string pAS_PROJ_CD)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[2];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pAS_PROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_DAYWRITE_DAY_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }

        return dsReturn;
    }
    #endregion

    #region == 업무직종 리스트 조회 ==

    /// <summary>
    /// 업무직종 리스트 조회
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    private DataSet Select_DDDWCLASS_NM_S_c()
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[1];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_DDDWCLASS_NM_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }

        return dsReturn;
    }
    #endregion

    #region == 협력업체 리스트 조회 ==

    /// <summary>
    /// 업무직종 리스트 조회
    /// </summary>

    /// <returns></returns>
    private DataSet Select_DDDWCLASS_NM_S2_c()
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[1];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_DDDWCLASS_NM_S2", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }

        return dsReturn;
    }
    #endregion

    #region == 관련증빙 리스트 조회 ==

    /// <summary>
    /// 관련증빙 리스트 조회
    /// </summary>

    /// <returns></returns>
    private DataSet Select_DDDW_461_S_c()
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[1];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_DDDW_461_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }

        return dsReturn;
    }
    #endregion

    #region == 일용직 팀명리스트 조회 ==

    /// <summary>
    /// 일용직 팀명리스트 조회
    /// </summary>

    /// <returns></returns>
    private DataSet Select_DDDW_GROUPNM_ALL_S_c()
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[1];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_DDDW_GROUPNM_ALL_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }

        return dsReturn;
    }
    #endregion



    #region == 인원현황 조회 ==

    /// <summary>
    /// 인원현황 조회
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "인원현황(PROJ_CD,DT)")]
    public string Select_FPD220T_P(string pAS_PROJ_CD, string pAS_DT)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pAS_PROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", pAS_DT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_FPD220T_P", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }
    #endregion

    #region == 인원현황 - 팝업 조회 ==
    /// <summary>
    /// 인원현황 - 팝업 조회
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <param name="pAS_NAME"></param>
    /// <param name="pAS_GROUP_CD"></param>
    /// <param name="pNOT_IN"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "인원현황팝업(PROJ_CD,DT,NAME,GROUP_CD,NOT_IN)")]
    public string Select_PA100T(string pAS_PROJ_CD, string pAS_DT, string pAS_NAME, string pAS_GROUP_CD, string pNOT_IN)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[6];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pAS_PROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", pAS_DT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_NAME", pAS_NAME, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_GROUP_CD", pAS_GROUP_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_NOT_IN", pNOT_IN, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_DAYWORKER_POP1_LIST_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }
    #endregion

    #region == 인원현황 INSERT(Procedure : SP_D_FPD220T_I ) ==

    /// <summary>
    /// 인원현황 UPDATE
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 인원현황 INSERT(Procedure : SP_D_FPD220T_I )")]
    public int INSERT_D_FPD220T_I(DataSet pDs)
    {
        int nResult = 0;

        if (pDs == null || pDs.Tables[0].Rows.Count == 0)
            throw new Exception("저장할 데이터가 없습니다.");

        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                foreach (DataRow dr in pDs.Tables[0].Rows)
                {
                    System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[15];
                    oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_SEQ_NO", dr["SEQ_NO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_REMARK", dr["REMARK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_PAY", dr["PAY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_NAME", dr["NAME"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_INPUT", dr["INPUT"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_ID", dr["ID"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[7] = oDBManager.GetOraclePrameter("AS_GROUP_CD", dr["GROUP_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[8] = oDBManager.GetOraclePrameter("AS_FOOD_E", dr["FOOD_E"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[9] = oDBManager.GetOraclePrameter("AS_FOOD_D", dr["FOOD_D"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[10] = oDBManager.GetOraclePrameter("AS_FOOD_C", dr["FOOD_C"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[11] = oDBManager.GetOraclePrameter("AS_FOOD_B", dr["FOOD_B"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[12] = oDBManager.GetOraclePrameter("AS_FOOD_A", dr["FOOD_A"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[13] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[14] = oDBManager.GetOraclePrameter("AS_ACCUM", dr["ACCUM"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD220T_I", oIDataParameter);
                }

            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }
    #endregion

    #region == 인원현황 UPDATE(Procedure : SP_D_FPD220T_U ) ==

    /// <summary>
    /// 인원현황 UPDATE
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 인원현황 UPDATE(Procedure : SP_D_FPD220T_U )")]
    public int UPDATE_D_FPD220T_U1(DataSet pDs)
    {
        int nResult = 0;

        if (pDs == null || pDs.Tables[0].Rows.Count == 0)
            throw new Exception("저장할 데이터가 없습니다.");

        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                foreach (DataRow dr in pDs.Tables[0].Rows)
                {
                    System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[15];
                    oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_SEQ_NO", dr["SEQ_NO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_REMARK", dr["REMARK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_PAY", dr["PAY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_NAME", dr["NAME"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_INPUT", dr["INPUT"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_ID", dr["ID"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[7] = oDBManager.GetOraclePrameter("AS_GROUP_CD", dr["GROUP_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[8] = oDBManager.GetOraclePrameter("AS_FOOD_E", dr["FOOD_E"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[9] = oDBManager.GetOraclePrameter("AS_FOOD_D", dr["FOOD_D"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[10] = oDBManager.GetOraclePrameter("AS_FOOD_C", dr["FOOD_C"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[11] = oDBManager.GetOraclePrameter("AS_FOOD_B", dr["FOOD_B"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[12] = oDBManager.GetOraclePrameter("AS_FOOD_A", dr["FOOD_A"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[13] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[14] = oDBManager.GetOraclePrameter("AS_ACCUM", dr["ACCUM"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD220T_U", oIDataParameter);
                }

            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }
    #endregion

    #region == 인원현황 DELETE(Procedure : SP_D_FPD220T_D ) ==
    /// <summary>
    /// 인원현황 DELETE
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 인원현황 DELETE(Procedure : SP_D_FPD220T_D )")]
    public int DELETE_D_FPD220T_D(DataSet pDs)
    {
        int nResult = 0;

        if (pDs == null || pDs.Tables[0].Rows.Count == 0)
            throw new Exception("삭제할 데이터가 없습니다.");

        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                foreach (DataRow dr in pDs.Tables[0].Rows)
                {
                    System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                    oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_SEQ_NO", dr["SEQ_NO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD220T_D", oIDataParameter);
                }

            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }
    #endregion

    #region == 인원현황 SAVE(Procedure : SP_D_FPD220T_U,SP_D_FPD220T_I,SP_D_FPD220T_D ) ==

    /// <summary>
    /// 인원현황 INSERT,UPDATE
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 인원현황 SAVE(INSER,UPDATE,DELETE)(Procedure : SP_D_FPD220T_U,SP_D_FPD220T_I,SP_D_FPD220T_D )")]
    public int SAVE_D_FPD220T_IU(DataSet pDs)
    {
        int nResult = 0;

        if (pDs == null || pDs.Tables[0].Rows.Count == 0)
            throw new Exception("저장할 데이터가 없습니다.");

        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                foreach (DataRow dr in pDs.Tables[0].Rows)
                {
                    if (dr.Table.Columns.Contains("Deleted_Id") && dr["Deleted_Id"].ToString().Equals("0"))
                    {
                        System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                        oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_SEQ_NO", dr["SEQ_NO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD220T_D", oIDataParameter);
                    }
                    else if (dr.Table.Columns.Contains("Created_Id") && dr["Created_Id"].ToString().Equals("0"))
                    {
                        System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[15];
                        oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_SEQ_NO", dr["SEQ_NO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_REMARK", dr["REMARK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_PAY", dr["PAY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_NAME", dr["NAME"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_INPUT", dr["INPUT"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_ID", dr["ID"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[7] = oDBManager.GetOraclePrameter("AS_GROUP_CD", dr["GROUP_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[8] = oDBManager.GetOraclePrameter("AS_FOOD_E", dr["FOOD_E"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[9] = oDBManager.GetOraclePrameter("AS_FOOD_D", dr["FOOD_D"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[10] = oDBManager.GetOraclePrameter("AS_FOOD_C", dr["FOOD_C"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[11] = oDBManager.GetOraclePrameter("AS_FOOD_B", dr["FOOD_B"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[12] = oDBManager.GetOraclePrameter("AS_FOOD_A", dr["FOOD_A"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[13] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[14] = oDBManager.GetOraclePrameter("AS_ACCUM", dr["ACCUM"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD220T_I", oIDataParameter);
                    }
                    else
                    {
                        System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[15];
                        oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_SEQ_NO", dr["SEQ_NO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_REMARK", dr["REMARK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_PAY", dr["PAY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_NAME", dr["NAME"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_INPUT", dr["INPUT"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_ID", dr["ID"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[7] = oDBManager.GetOraclePrameter("AS_GROUP_CD", dr["GROUP_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[8] = oDBManager.GetOraclePrameter("AS_FOOD_E", dr["FOOD_E"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[9] = oDBManager.GetOraclePrameter("AS_FOOD_D", dr["FOOD_D"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[10] = oDBManager.GetOraclePrameter("AS_FOOD_C", dr["FOOD_C"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[11] = oDBManager.GetOraclePrameter("AS_FOOD_B", dr["FOOD_B"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[12] = oDBManager.GetOraclePrameter("AS_FOOD_A", dr["FOOD_A"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[13] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[14] = oDBManager.GetOraclePrameter("AS_ACCUM", dr["ACCUM"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD220T_U", oIDataParameter);
                    }
                }

            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }
    #endregion

    #region == 인원 등록 INSERT(Procedure : SP_D_PA100T_MASTER_I ) ==


    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 인원 등록 INSERT(Procedure : SP_D_PA100T_MASTER_I )")]
    public int INSERT_D_PA100T_MASTER_I(string pNAME, string pJUMIN_NO, string pCLASS, string pADDRESS, string pTEL, string pHP
                                      , string pBANK, string pACCOUNT_NO, int pPAY, string pEMP_PER, int pHEL_AMT, int pNAT_AMT
                                      , string pIN_DATE, string pOUT_DATE, string pGROUP_CD)
    {
        int nResult = 0;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[15];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_NAME", pNAME, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_JUMIN_NO", pJUMIN_NO, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_CLASS", pCLASS, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_ADDRESS", pADDRESS, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_TEL", pTEL, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_HP", pHP, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_BANK", pBANK, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[7] = oDBManager.GetOraclePrameter("AS_ACCOUNT_NO", pACCOUNT_NO, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[8] = oDBManager.GetOraclePrameter("AS_PAY", pPAY, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                oIDataParameter[9] = oDBManager.GetOraclePrameter("AS_EMP_PER", pEMP_PER, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[10] = oDBManager.GetOraclePrameter("AS_HEL_AMT", pHEL_AMT, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                oIDataParameter[11] = oDBManager.GetOraclePrameter("AS_NAT_AMT", pNAT_AMT, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                oIDataParameter[12] = oDBManager.GetOraclePrameter("AS_INDATE", pIN_DATE, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[13] = oDBManager.GetOraclePrameter("AS_OUT_DATE", pOUT_DATE, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[14] = oDBManager.GetOraclePrameter("AS_GROUP_CD", pGROUP_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_PA100T_MASTER_I", oIDataParameter);
            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }

    #endregion

    #region == 인원 마스터 조회 ==

    /// <summary>
    /// 인원 마스터 조회
    /// </summary>
    /// <param name="pCODE"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "인원 마스터 조회")]
    public DataSet Select_D_PA100T_MASTER_S(string pCODE)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[2];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_CODE", pCODE, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_PA100T_MASTER_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }

        return dsReturn;
    }
    #endregion


    #region == 인원 마스터 UPDATE(Procedure : SP_D_FPD200T_S ) ==
    /// <summary>
    /// 인원 마스터 UPDATE
    /// </summary>
    /// <param name="pCode"></param>
    /// <param name="pNAME"></param>
    /// <param name="pJUMIN_NO"></param>
    /// <param name="pCLASS"></param>
    /// <param name="pADDRESS"></param>
    /// <param name="pTEL"></param>
    /// <param name="pHP"></param>
    /// <param name="pBANK"></param>
    /// <param name="pACCOUNT_NO"></param>
    /// <param name="pPAY"></param>
    /// <param name="pEMP_PER"></param>
    /// <param name="pHEL_AMT"></param>
    /// <param name="pNAT_AMT"></param>
    /// <param name="pIN_DATE"></param>
    /// <param name="pOUT_DATE"></param>
    /// <param name="pGROUP_CD"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 인원 마스터 UPDATE(Procedure : SP_D_PA100T_MASTER_U )")]
    public int UPDATE_D_PA100T_MASTER_U(string pCode, string pNAME, string pJUMIN_NO, string pCLASS, string pADDRESS, string pTEL, string pHP
                                      , string pBANK, string pACCOUNT_NO, int pPAY, string pEMP_PER, int pHEL_AMT, int pNAT_AMT
                                      , string pIN_DATE, string pOUT_DATE, string pGROUP_CD)
    {
        int nResult = 0;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[16];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_CODE", pCode, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_NAME", pNAME, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_JUMIN_NO", pJUMIN_NO, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_CLASS", pCLASS, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_ADDRESS", pADDRESS, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_TEL", pTEL, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_HP", pHP, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[7] = oDBManager.GetOraclePrameter("AS_BANK", pBANK, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[8] = oDBManager.GetOraclePrameter("AS_ACCOUNT_NO", pACCOUNT_NO, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[9] = oDBManager.GetOraclePrameter("AS_PAY", pPAY, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                oIDataParameter[10] = oDBManager.GetOraclePrameter("AS_EMP_PER", pEMP_PER, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[11] = oDBManager.GetOraclePrameter("AS_HEL_AMT", pHEL_AMT, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                oIDataParameter[12] = oDBManager.GetOraclePrameter("AS_NAT_AMT", pNAT_AMT, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                oIDataParameter[13] = oDBManager.GetOraclePrameter("AS_INDATE", pIN_DATE, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[14] = oDBManager.GetOraclePrameter("AS_OUT_DATE", pOUT_DATE, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[15] = oDBManager.GetOraclePrameter("AS_GROUP_CD", pGROUP_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_PA100T_MASTER_U", oIDataParameter);
            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }
    #endregion

    #region == 인원마스터 삭제  (Procedure : SP_D_PA100T_MASTER_D ) ==

    /// <summary>
    ///인원마스터 삭제(Procedure : SP_D_PA100T_MASTER_D )
    /// </summary>
    /// <param name="pCODE"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 인원마스터 삭제(Procedure : SP_D_PA100T_MASTER_D )")]
    public int DELETE_D_PA100T_MASTER_D(string pCODE)
    {
        int nResult = 0;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[1];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_CODE", pCODE, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_PA100T_MASTER_D", oIDataParameter);
            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }

    #endregion


    #region  대분류 조회
    /// <summary>
    /// 대분류 조회
    /// </summary>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "대분류 조회")]
    public string Select_DDDW_MK_CLASS()
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[1];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_DDDW_MK_CLASS_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }

        return this.CompressDataSet(dsReturn);
    }
    #endregion

    #region 소분류조회
    /// <summary>
    /// 소분류조회
    /// </summary>
    /// <param name="pCLASS"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "소분류 조회")]
    public string Select_DDDW_MK_CLASS2(string pCLASS)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[2];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_CLASS", pCLASS, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_DDDW_MK_CLASS_S2", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }

        return this.CompressDataSet(dsReturn);
    }
    #endregion

    #region 표준DB자재 조회
    /// <summary>
    /// 표준DB자재 조회
    /// </summary>
    /// <param name="pCLASS"></param>
    /// <param name="pMK_CLASS"></param>
    /// <param name="pNAME"></param>
    /// <param name="pSPEC"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "표준DB자재 조회")]
    public string Select_D_DAYWRITE_POP8_2_S(string pCLASS, string pMK_CLASS, string pNAME, string pSPEC)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[5];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_CLASS", pCLASS, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_MK_CLASS", pMK_CLASS, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_NAME", pNAME, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_SPEC", pSPEC, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_DAYWRITE_POP8_2_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }

        return this.CompressDataSet(dsReturn);
    }
    #endregion



    #region == 주자재현황 조회 ==
    /// <summary>
    /// 주자재현황 조회
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "주자재현황(PROJ_CD,DT)")]
    public string Select_FPD240T_P(string pAS_PROJ_CD, string pAS_DT)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pAS_PROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", pAS_DT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_FPD240T_P", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }
    #endregion

    #region == 주자재현황 - 팝업 조회 ==
    /// <summary>
    /// 주자재현황 - 팝업 조회 - 주자재(업체리스트)
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pCOMP_NM"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "주자재현황팝업-주자재(업체리스트)(PROJ_CD,COMP_NM)")]
    public string Select_D_DAYWRITE_POP2_B_CUST_S(string pPROJ_CD, string pCOMP_NM)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pPROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_COMP_NM", pCOMP_NM, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_DAYWRITE_POP2_B_CUST_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }


    /// <summary>
    /// 주자재현황 - 팝업 조회 - 주자재(아이템)
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pBIZ_REGNO"></param>
    /// <param name="pNAME"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "주자재현황팝업-주자재(아이템)(PROJ_CD,BIZ_REGNO,NAME)")]
    public string Select_D_DAYWRITE_POP2_B_ITEM_S(string pPROJ_CD, string pBIZ_REGNO, string pNAME)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[4];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pPROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_BIZ_REGNO", pBIZ_REGNO, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_NAME", pNAME, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_DAYWRITE_POP2_B_ITEM_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }


    /// <summary>
    /// 주자재현황 - 팝업 조회 - 발주대상관리
    /// </summary>
    /// <param name="pCOMP_NM"></param>
    /// <param name="pNAME"></param>
    /// <param name="pFRDT"></param>
    /// <param name="pTODT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "주자재현황팝업-발주대상관리(COMP_NM,NAME,FRDT,TODT)")]
    public string Select_D_DAYWRITE_POP2_C_ITEM_S(string pCOMP_NM, string pNAME, string pFRDT, string pTODT)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[5];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_COMP_NM", pCOMP_NM, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_NAME", pNAME, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_FRDT", pFRDT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_TODT", pTODT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_DAYWRITE_POP2_C_ITEM_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }


    /// <summary>
    /// 주자재현황팝업-업체별발주단가(업체리스트)
    /// </summary>
    /// <param name="pCOMP_NM"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "주자재현황팝업-업체별발주단가(업체리스트)(COMP_NM)")]
    public string Select_D_DAYWRITE_POP2_D_CUST_S(string pCOMP_NM)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[2];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_COMP_NM", pCOMP_NM, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_DAYWRITE_POP2_D_CUST_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }

    /// <summary>
    /// 주자재현황팝업-업체별발주단가(아이템)
    /// </summary>
    /// <param name="pPROJ_CD"></param>
    /// <param name="pDT"></param>
    /// <param name="pBIZ_REGNO"></param>
    /// <param name="pNAME"></param>
    /// <param name="pFRDT"></param>
    /// <param name="pTODT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "주자재현황팝업-업체별발주단가(아이템)(PROJ_CD,BIZ_REGNO,NAME)")]
    public string Select_D_DAYWRITE_POP2_D_ITEM_S(string pPROJ_CD, string pDT, string pBIZ_REGNO, string pNAME, string pFRDT, string pTODT)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[7];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pPROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", pDT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_BIZ_REGNO", pBIZ_REGNO, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_NAME", pNAME, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_FRDT", pFRDT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_TODT", pTODT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_DAYWRITE_POP2_D_ITEM_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }


    /// <summary>
    /// 주자재현황팝업-공종계획
    /// </summary>
    /// <param name="pPROJ_CD"></param>
    /// <param name="pDT"></param>
    /// <param name="pCUST"></param>
    /// <param name="pSUB_ITEM_NAME"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "주자재현황팝업-공종계획(PROJ_CD,DT,CUST, SUB_ITEM_NAME)")]
    public string Select_D_DAYWRITE_POP2_S(string pPROJ_CD, string pDT, string pCUST, string pSUB_ITEM_NAME)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[5];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pPROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", pDT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_CUST", pCUST, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_SUB_ITEM_NM", pSUB_ITEM_NAME, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_DAYWRITE_POP2_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }

    #endregion

    #region == 주자재현황 INSERT(Procedure : SP_D_FPD240T_I ) ==

    /// <summary>
    /// 주자재현황 INSERT
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 주자재현황 INSERT(Procedure : SP_D_FPD240T_I )")]
    public int INSERT_D_FPD240T_I(DataSet pDs)
    {
        int nResult = 0;

        if (pDs == null || pDs.Tables[0].Rows.Count == 0)
            throw new Exception("저장할 데이터가 없습니다.");

        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                foreach (DataRow dr in pDs.Tables[0].Rows)
                {
                    System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[25];
                    oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_SEQ_NO", dr["SEQ_NO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_NAME", dr["NAME"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_SPEC", dr["SPEC"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_P_QTY", dr["P_QTY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_A_IN_QTY", dr["A_IN_QTY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[7] = oDBManager.GetOraclePrameter("AS_IN_QTY", dr["IN_QTY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[8] = oDBManager.GetOraclePrameter("AS_A_USE_QTY", dr["A_USE_QTY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[9] = oDBManager.GetOraclePrameter("AS_USE_QTY", dr["USE_QTY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[10] = oDBManager.GetOraclePrameter("AS_REMARK", dr["REMARK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[11] = oDBManager.GetOraclePrameter("AS_PAY", dr["PAY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[12] = oDBManager.GetOraclePrameter("AS_VAT_CHK", dr["VAT_CHK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[13] = oDBManager.GetOraclePrameter("AS_PROOF", string.IsNullOrEmpty(dr["PROOF"].ToString()) ? DBNull.Value : dr["PROOF"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[14] = oDBManager.GetOraclePrameter("AS_BIZ_REGNO", dr["BIZ_REGNO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[15] = oDBManager.GetOraclePrameter("AS_ATTACT", dr["ATTACT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[16] = oDBManager.GetOraclePrameter("AS_REMAINDER", dr["REMAINDER"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[17] = oDBManager.GetOraclePrameter("AS_CD", dr["CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[18] = oDBManager.GetOraclePrameter("AS_ITEM_GUBUN", dr["ITEM_GUBUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[19] = oDBManager.GetOraclePrameter("AS_UNIT", dr["UNIT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[20] = oDBManager.GetOraclePrameter("AS_ZIP_OFFICE", dr["ZIP_OFFICE"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[21] = oDBManager.GetOraclePrameter("AS_ZIP_HYUN", dr["ZIP_HYUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[22] = oDBManager.GetOraclePrameter("AS_SU_OFFICE", dr["SU_OFFICE"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[23] = oDBManager.GetOraclePrameter("AS_SU_HYUN", dr["SU_HYUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[24] = oDBManager.GetOraclePrameter("AS_BIGO", dr["BIGO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);

                    nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD240T_I", oIDataParameter);
                }

            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }
    #endregion

    #region == 주자재현황 UPDATE(Procedure : SP_D_FPD240T_U ) ==

    /// <summary>
    /// 주자재현황 UPDATE
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 주자재현황 UPDATE(Procedure : SP_D_FPD240T_U )")]
    public int UPDATE_D_FPD240T_U1(DataSet pDs)
    {
        int nResult = 0;

        if (pDs == null || pDs.Tables[0].Rows.Count == 0)
            throw new Exception("저장할 데이터가 없습니다.");

        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                foreach (DataRow dr in pDs.Tables[0].Rows)
                {
                    System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[25];
                    oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_SEQ_NO", dr["SEQ_NO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_NAME", dr["NAME"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_SPEC", dr["SPEC"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_P_QTY", dr["P_QTY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_A_IN_QTY", dr["A_IN_QTY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[7] = oDBManager.GetOraclePrameter("AS_IN_QTY", dr["IN_QTY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[8] = oDBManager.GetOraclePrameter("AS_A_USE_QTY", dr["A_USE_QTY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[9] = oDBManager.GetOraclePrameter("AS_USE_QTY", dr["USE_QTY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[10] = oDBManager.GetOraclePrameter("AS_REMARK", dr["REMARK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[11] = oDBManager.GetOraclePrameter("AS_PAY", dr["PAY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[12] = oDBManager.GetOraclePrameter("AS_VAT_CHK", dr["VAT_CHK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[13] = oDBManager.GetOraclePrameter("AS_PROOF", string.IsNullOrEmpty(dr["PROOF"].ToString()) ? DBNull.Value : dr["PROOF"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[14] = oDBManager.GetOraclePrameter("AS_BIZ_REGNO", dr["BIZ_REGNO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[15] = oDBManager.GetOraclePrameter("AS_ATTACT", dr["ATTACT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[16] = oDBManager.GetOraclePrameter("AS_REMAINDER", dr["REMAINDER"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[17] = oDBManager.GetOraclePrameter("AS_CD", dr["CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[18] = oDBManager.GetOraclePrameter("AS_ITEM_GUBUN", dr["ITEM_GUBUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[19] = oDBManager.GetOraclePrameter("AS_UNIT", dr["UNIT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[20] = oDBManager.GetOraclePrameter("AS_ZIP_OFFICE", dr["ZIP_OFFICE"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[21] = oDBManager.GetOraclePrameter("AS_ZIP_HYUN", dr["ZIP_HYUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[22] = oDBManager.GetOraclePrameter("AS_SU_OFFICE", dr["SU_OFFICE"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[23] = oDBManager.GetOraclePrameter("AS_SU_HYUN", dr["SU_HYUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[24] = oDBManager.GetOraclePrameter("AS_BIGO", dr["BIGO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);

                    nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD240T_U", oIDataParameter);
                }

            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }
    #endregion

    #region == 주자재현황 DELETE(Procedure : SP_D_FPD240T_D ) ==
    /// <summary>
    /// 주자재현황 DELETE
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 주자재현황 DELETE(Procedure : SP_D_FPD240T_D )")]
    public int DELETE_D_FPD240T_D(DataSet pDs)
    {
        int nResult = 0;

        if (pDs == null || pDs.Tables[0].Rows.Count == 0)
            throw new Exception("삭제할 데이터가 없습니다.");

        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                foreach (DataRow dr in pDs.Tables[0].Rows)
                {
                    System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                    oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_SEQ_NO", dr["SEQ_NO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD240T_D", oIDataParameter);
                }

            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }
    #endregion

    #region == 주자재현황 SAVE(Procedure : SP_D_FPD240T_U,SP_D_FPD240T_I,SP_D_FPD240T_D ) ==

    /// <summary>
    /// 주자재현황 INSERT,UPDATE
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 주자재현황 SAVE(INSER,UPDATE,DELETE)(Procedure : SP_D_FPD240T_U,SP_D_FPD240T_I,SP_D_FPD240T_D )")]
    public int SAVE_D_FPD240T_IU(DataSet pDs)
    {
        int nResult = 0;

        if (pDs == null || pDs.Tables[0].Rows.Count == 0)
            throw new Exception("저장할 데이터가 없습니다.");

        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                foreach (DataRow dr in pDs.Tables[0].Rows)
                {
                    if (dr.Table.Columns.Contains("Deleted_Id") && dr["Deleted_Id"].ToString().Equals("0"))
                    {
                        System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                        oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_SEQ_NO", dr["SEQ_NO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD240T_D", oIDataParameter);
                    }
                    else if (dr.Table.Columns.Contains("Created_Id") && dr["Created_Id"].ToString().Equals("0"))
                    {
                        System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[25];
                        oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_SEQ_NO", dr["SEQ_NO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_NAME", dr["NAME"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_SPEC", dr["SPEC"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_P_QTY", dr["P_QTY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_A_IN_QTY", dr["A_IN_QTY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[7] = oDBManager.GetOraclePrameter("AS_IN_QTY", dr["IN_QTY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[8] = oDBManager.GetOraclePrameter("AS_A_USE_QTY", dr["A_USE_QTY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[9] = oDBManager.GetOraclePrameter("AS_USE_QTY", dr["USE_QTY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[10] = oDBManager.GetOraclePrameter("AS_REMARK", dr["REMARK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[11] = oDBManager.GetOraclePrameter("AS_PAY", dr["PAY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[12] = oDBManager.GetOraclePrameter("AS_VAT_CHK", dr["VAT_CHK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[13] = oDBManager.GetOraclePrameter("AS_PROOF", string.IsNullOrEmpty(dr["PROOF"].ToString()) ? DBNull.Value : dr["PROOF"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[14] = oDBManager.GetOraclePrameter("AS_BIZ_REGNO", dr["BIZ_REGNO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[15] = oDBManager.GetOraclePrameter("AS_ATTACT", dr["ATTACT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[16] = oDBManager.GetOraclePrameter("AS_REMAINDER", dr["REMAINDER"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[17] = oDBManager.GetOraclePrameter("AS_CD", dr["CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[18] = oDBManager.GetOraclePrameter("AS_ITEM_GUBUN", dr["ITEM_GUBUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[19] = oDBManager.GetOraclePrameter("AS_UNIT", dr["UNIT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[20] = oDBManager.GetOraclePrameter("AS_ZIP_OFFICE", dr["ZIP_OFFICE"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[21] = oDBManager.GetOraclePrameter("AS_ZIP_HYUN", dr["ZIP_HYUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[22] = oDBManager.GetOraclePrameter("AS_SU_OFFICE", dr["SU_OFFICE"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[23] = oDBManager.GetOraclePrameter("AS_SU_HYUN", dr["SU_HYUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[24] = oDBManager.GetOraclePrameter("AS_BIGO", dr["BIGO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);

                        nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD240T_I", oIDataParameter);
                    }
                    else
                    {
                        System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[25];
                        oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_SEQ_NO", dr["SEQ_NO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_NAME", dr["NAME"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_SPEC", dr["SPEC"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_P_QTY", dr["P_QTY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_A_IN_QTY", dr["A_IN_QTY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[7] = oDBManager.GetOraclePrameter("AS_IN_QTY", dr["IN_QTY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[8] = oDBManager.GetOraclePrameter("AS_A_USE_QTY", dr["A_USE_QTY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[9] = oDBManager.GetOraclePrameter("AS_USE_QTY", dr["USE_QTY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[10] = oDBManager.GetOraclePrameter("AS_REMARK", dr["REMARK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[11] = oDBManager.GetOraclePrameter("AS_PAY", dr["PAY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[12] = oDBManager.GetOraclePrameter("AS_VAT_CHK", dr["VAT_CHK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[13] = oDBManager.GetOraclePrameter("AS_PROOF", string.IsNullOrEmpty(dr["PROOF"].ToString()) ? DBNull.Value : dr["PROOF"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[14] = oDBManager.GetOraclePrameter("AS_BIZ_REGNO", dr["BIZ_REGNO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[15] = oDBManager.GetOraclePrameter("AS_ATTACT", dr["ATTACT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[16] = oDBManager.GetOraclePrameter("AS_REMAINDER", dr["REMAINDER"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[17] = oDBManager.GetOraclePrameter("AS_CD", dr["CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[18] = oDBManager.GetOraclePrameter("AS_ITEM_GUBUN", dr["ITEM_GUBUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[19] = oDBManager.GetOraclePrameter("AS_UNIT", dr["UNIT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[20] = oDBManager.GetOraclePrameter("AS_ZIP_OFFICE", dr["ZIP_OFFICE"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[21] = oDBManager.GetOraclePrameter("AS_ZIP_HYUN", dr["ZIP_HYUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[22] = oDBManager.GetOraclePrameter("AS_SU_OFFICE", dr["SU_OFFICE"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[23] = oDBManager.GetOraclePrameter("AS_SU_HYUN", dr["SU_HYUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[24] = oDBManager.GetOraclePrameter("AS_BIGO", dr["BIGO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);

                        nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD240T_U", oIDataParameter);
                    }
                }

            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }
    #endregion

    #region == 자재 마스터 조회 ==

    /// <summary>
    /// 자재 마스터 조회
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "자재 마스터 조회")]
    public string Select_D_MA_DB_S2(string pMK_CLASS, string pCLASS, string pNAME, string pFDT, string pTDT)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[6];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_MK_CLASS", pMK_CLASS, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_CLASS", pCLASS, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_NAME", pNAME, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_FDT", pFDT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_TDT", pTDT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_MA_DB_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }
    #endregion


    #region == 자재마스터 SAVE(Procedure : SP_D_DAYEATPAY_I,SP_D_DAYEATPAY_U,SP_D_DAYEATPAY_D ) ==

    /// <summary>
    /// 자재마스터 INSERT,UPDATE,DELETE
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 자재마스터 SAVE(INSER,UPDATE,DELETE)(Procedure : SP_D_MA_DB_U,SP_D_MA_DB_I,SP_D_MA_DB_D )")]
    public int SAVE_D_MA_DB_IUD(DataSet pDs)
    {
        int nResult = 0;

        if (pDs == null || pDs.Tables[0].Rows.Count == 0)
            throw new Exception("저장할 데이터가 없습니다.");

        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                foreach (DataRow dr in pDs.Tables[0].Rows)
                {
                    if (dr.Table.Columns.Contains("Deleted_Id") && dr["Deleted_Id"].ToString().Equals("0"))
                    {
                        System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[1];
                        oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_MA_CD", dr["MA_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_MA_DB_D", oIDataParameter);
                    }
                    else if (dr.Table.Columns.Contains("Created_Id") && dr["Created_Id"].ToString().Equals("0"))
                    {
                        System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[8];

                        oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_MA_DT", dr["MA_DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_NAME", dr["NAME"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_SPEC", dr["SPEC"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_UNIT", dr["UNIT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_UC", dr["UC"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_CLASS", dr["CLASS"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_REG_NAME", dr["REG_NAME"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[7] = oDBManager.GetOraclePrameter("AS_REMARK", dr["REMARK"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);

                        nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_MA_DB_I", oIDataParameter);
                    }
                    else
                    {
                        System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[7];

                        oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_MA_CD", dr["MA_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_NAME", dr["NAME"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_SPEC", dr["SPEC"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_UNIT", dr["UNIT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_UC", dr["UC"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_REG_NAME", dr["REG_NAME"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_REMARK", dr["REMARK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);

                        nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_MA_DB_U", oIDataParameter);
                    }
                }

            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }
    #endregion


    #region == 자재마스터 등록 INSERT(Procedure : SP_D_MA_DB_I ) ==

    /// <summary>
    /// 자재마스터 등록
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 자재마스터 등록(Procedure : SP_D_MA_DB_I )")]
    public int INSERT_D_MA_DB_I(string pMA_DT, string pNAME, string pSPEC, string pUNIT, string pUC, string pCLASS, string pREG_NAME, string pREMARK)
    {
        int nResult = 0;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[8];

                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_MA_DT", pMA_DT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_NAME", pNAME, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_SPEC", pSPEC, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_UNIT", pUNIT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_UC", pUC, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_CLASS", pCLASS, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_REG_NAME", pREG_NAME, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[7] = oDBManager.GetOraclePrameter("AS_REMARK", pREMARK, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);

                nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_MA_DB_I", oIDataParameter);
            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }

    #endregion

    #region == 자재마스터 수정 Update(Procedure : SP_DW_FPD300T_I ) ==

    /// <summary>
    /// 자재마스터 수정
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 자재마스터 수정(Procedure : SP_DW_FPD300T_I )")]
    public int UPDATE_D_MA_DB_U(string pMA_CD, string pNAME, string pSPEC, string pUNIT, string pUC, string pREG_NAME, string pREMARK)
    {
        int nResult = 0;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[7];

                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_MA_CD", pMA_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_NAME", pNAME, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_SPEC", pSPEC, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_UNIT", pUNIT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_UC", pUC, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_REG_NAME", pREG_NAME, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_REMARK", pREMARK, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);

                nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_MA_DB_U", oIDataParameter);
            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }

    #endregion

    #region == 자재 마스터 조회2 ==

    /// <summary>
    /// 자재 마스터 조회2
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "자재 마스터 조회2")]
    public string Select_D_MA_DB_S(string pMA_CD)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[2];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_MA_CD", pMA_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_MA_DB_S2", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }
    #endregion



    #region == 업체별발주단가 SAVE(Procedure : SP_DW_FPD300T_U,SP_DW_FPD300T_D ) ==

    /// <summary>
    /// 업체별발주단가 UPDATE,DELETE
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 업체별발주단가 SAVE(UPDATE,DELETE)(Procedure : SP_DW_FPD300T_D,SP_DW_FPD300T_U )")]
    public int SAVE_DW_FPD300T_UD(DataSet pDs)
    {
        int nResult = 0;

        if (pDs == null || pDs.Tables[0].Rows.Count == 0)
            throw new Exception("저장할 데이터가 없습니다.");

        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                foreach (DataRow dr in pDs.Tables[0].Rows)
                {
                    if (dr.Table.Columns.Contains("Deleted_Id") && dr["Deleted_Id"].ToString().Equals("0"))
                    {
                        System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[1];
                        oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_CD", dr["CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_DW_FPD300T_D", oIDataParameter);
                    }
                    else if (dr.Table.Columns.Contains("Created_Id") && dr["Created_Id"].ToString().Equals("0"))
                    {
                    }
                    else
                    {
                        System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[7];

                        oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_CD", dr["CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_NAME", dr["NAME"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_SPEC", dr["SPEC"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_UNIT", dr["UNIT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_UC", dr["UC"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_REMARK", dr["REMARK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);

                        nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_DW_FPD300T_U", oIDataParameter);
                    }
                }

            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }
    #endregion



    #region == 업체별발주단가 등록 INSERT(Procedure : SP_DW_FPD300T_I ) ==

    /// <summary>
    /// 업체별발주단가 등록
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 업체별발주단가 등록(Procedure : SP_DW_FPD300T_I )")]
    public int INSERT_DW_FPD300T_I(string pMA_CD, string pNAME, string pSPEC, string pUNIT, string pCUST, string pUC, string pREMARK)
    {
        int nResult = 0;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[7];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_MA_CD", pMA_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_NAME", pNAME, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_SPEC", pSPEC, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_UNIT", pUNIT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_CUST", pCUST, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_UC", pUC, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_REMARK", pREMARK, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_DW_FPD300T_I", oIDataParameter);
            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }

    #endregion


    #region == 자재 마스터 대분류 조회 ==

    /// <summary>
    /// 자재 마스터 대분류 조회
    /// </summary>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "자재 마스터 대분류 조회")]
    public string Select_SP_DDDW_MCLASS_LEVEL1_S()
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[1];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_DDDW_MCLASS_LEVEL1_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }
    #endregion


    #region == 자재 마스터 소분류 조회 ==

    /// <summary>
    /// 자재 마스터 소분류 조회
    /// </summary>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "자재 마스터 소분류 조회")]
    public string Select_SP_DDDW_MCLASS_LEVEL2_S(string pMK_CLASS)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[2];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_MK_CLASS", pMK_CLASS, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_DDDW_MCLASS_LEVEL2_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }
    #endregion



    #region == 장비현황 조회 ==

    /// <summary>
    /// 장비현황 조회
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "장비현황조회(PROJ_CD,DT)")]
    public string Select_D_FPD230T_S(string pAS_PROJ_CD, string pAS_DT)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pAS_PROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", pAS_DT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD230T_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }
    #endregion

    #region == 장비현황 - 팝업 조회 ==
    /// <summary>
    /// 장비현황 - 팝업 조회 - 장비현황리스트(업체리스트)
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pCOMP_NM"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "장비현황 - 팝업 조회 - 장비현황리스트(PROJ_CD,COMP_NM)")]
    public string Select_D_DAYWRITE_POP3_B_CUST_S(string pPROJ_CD, string pCOMP_NM)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pPROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_COMP_NM", pCOMP_NM, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_DAYWRITE_POP3_B_CUST_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }


    /// <summary>
    /// 장비현황 - 팝업 조회 - 장비현황리스트(아이템)
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pBIZ_REGNO"></param>
    /// <param name="pNAME"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "장비현황 - 팝업 조회 - 장비현황리스트(PROJ_CD,BIZ_REGNO,NAME)")]
    public string Select_D_DAYWRITE_POP3_B_ITEM_S(string pPROJ_CD, string pBIZ_REGNO, string pNAME)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[4];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pPROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_BIZ_REGNO", pBIZ_REGNO, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_NAME", pNAME, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_DAYWRITE_POP3_B_ITEM_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }

    /// <summary>
    /// 장비현황 - 팝업 조회 - 장비코드리스트(아이템)
    /// </summary>
    /// <param name="pEQUIP"></param>
    /// <param name="pBIZ_REGNO"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "장비현황 - 팝업 조회 - 장비코드리스트(아이템)(EQUIP,BIZ_REGNO)")]
    public string Select_D_EQUIP_3_S(string pEQUIP, string pBIZ_REGNO)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_EQUIP", pEQUIP, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_BIZ_REGNO", pBIZ_REGNO, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_EQUIP_3_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }


    #region == 장비업체리스트 조회 ==
    /// <summary>
    /// 장비업체리스트 조회
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <param name="pAS_NAME"></param>
    /// <param name="pAS_GROUP_CD"></param>
    /// <param name="pNOT_IN"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "장비업체리스트 조회(COMP_NM)")]
    public string Select_D_SELCOMJANGBI_CORP_S(string pCOMP_NM)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[2];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_COMP_NM", pCOMP_NM, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_SELCOMJANGBI_CORP_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }
    #endregion

    #endregion

    #region == 장비종류리스트 조회 ==

    /// <summary>
    /// 장비종류리스트 조회
    /// </summary>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "장비종류리스트")]
    public string Select_DDDW_EQUIP_KIND_S()
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[1];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_DDDW_EQUIP_KIND_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }

        return this.CompressDataSet(dsReturn);
    }
    #endregion

    #region == 장비업체리스트 조회 ==
    /// <summary>
    /// 장비업체리스트 조회(세양)
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <param name="pAS_NAME"></param>
    /// <param name="pAS_GROUP_CD"></param>
    /// <param name="pNOT_IN"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "장비업체리스트 조회(BIZ_REGNO, COMP_NM)")]
    public string Select_D_SELCOMJANGBI_CORP_SY_S(string pBIZ_REGNO, string pCOMP_NM)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_BIZ_REGNO", pBIZ_REGNO, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_COMP_NM", pCOMP_NM, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_SELCOMJANGBI_CORP_SY_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }
    #endregion

    #region == 장비현황 INSERT(Procedure : SP_D_FPD230T_I ) ==

    /// <summary>
    /// 장비현황 INSERT
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 장비현황 INSERT(Procedure : SP_D_FPD230T_I )")]
    public int INSERT_D_FPD230T_I(DataSet pDs)
    {
        int nResult = 0;

        if (pDs == null || pDs.Tables[0].Rows.Count == 0)
            throw new Exception("저장할 데이터가 없습니다.");

        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                foreach (DataRow dr in pDs.Tables[0].Rows)
                {
                    System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[27];
                    oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_ZIP_OFFICE", dr["ZIP_OFFICE"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_ZIP_HYUN", dr["ZIP_HYUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_VAT_CHK", dr["VAT_CHK"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_VAT", string.IsNullOrEmpty(dr["VAT"].ToString()) ? DBNull.Value : dr["VAT"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_UNIT", dr["UNIT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_SU_HYUN", dr["SU_HYUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_SPEC", dr["SPEC"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[7] = oDBManager.GetOraclePrameter("AS_SEQ_NO", dr["SEQ_NO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[8] = oDBManager.GetOraclePrameter("AS_REMARK", dr["REMARK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[9] = oDBManager.GetOraclePrameter("AS_REMAINDER", string.IsNullOrEmpty(dr["REMAINDER"].ToString()) ? DBNull.Value : dr["REMAINDER"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[10] = oDBManager.GetOraclePrameter("AS_PROOF", string.IsNullOrEmpty(dr["PROOF"].ToString()) ? DBNull.Value : dr["PROOF"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[11] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[12] = oDBManager.GetOraclePrameter("AS_PAYMENT", string.IsNullOrEmpty(dr["PAYMENT"].ToString()) ? DBNull.Value : dr["PAYMENT"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[13] = oDBManager.GetOraclePrameter("AS_INPUT", dr["INPUT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[14] = oDBManager.GetOraclePrameter("AS_FOOD_E", dr["FOOD_E"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[15] = oDBManager.GetOraclePrameter("AS_FOOD_D", dr["FOOD_D"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[16] = oDBManager.GetOraclePrameter("AS_FOOD_C", dr["FOOD_C"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[17] = oDBManager.GetOraclePrameter("AS_FOOD_B", dr["FOOD_B"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[18] = oDBManager.GetOraclePrameter("AS_FOOD_A", dr["FOOD_A"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[19] = oDBManager.GetOraclePrameter("AS_EQUIP_KIND", string.IsNullOrEmpty(dr["EQUIP_KIND"].ToString()) ? DBNull.Value : dr["EQUIP_KIND"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[20] = oDBManager.GetOraclePrameter("AS_EQUIP_CD", string.IsNullOrEmpty(dr["EQUIP_CD"].ToString()) ? DBNull.Value : dr["EQUIP_CD"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[21] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[22] = oDBManager.GetOraclePrameter("AS_COST", dr["COST"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[23] = oDBManager.GetOraclePrameter("AS_BIZ_REGNO", dr["BIZ_REGNO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[24] = oDBManager.GetOraclePrameter("AS_BIGO", dr["BIGO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[25] = oDBManager.GetOraclePrameter("AS_ATTACH", dr["ATTACH"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[26] = oDBManager.GetOraclePrameter("AS_ACCUM", string.IsNullOrEmpty(dr["ACCUM"].ToString()) ? DBNull.Value : dr["ACCUM"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);

                    nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD230T_I", oIDataParameter);
                }

            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }
    #endregion

    #region == 장비현황 UPDATE(Procedure : SP_D_FPD230T_U ) ==

    /// <summary>
    /// 장비현황 INSERT
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 장비현황 UPDATE(Procedure : SP_D_FPD230T_U )")]
    public int UPDATE_D_FPD230T_I(DataSet pDs)
    {
        int nResult = 0;

        if (pDs == null || pDs.Tables[0].Rows.Count == 0)
            throw new Exception("저장할 데이터가 없습니다.");

        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                foreach (DataRow dr in pDs.Tables[0].Rows)
                {
                    System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[27];
                    oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_ZIP_OFFICE", dr["ZIP_OFFICE"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_ZIP_HYUN", dr["ZIP_HYUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_VAT_CHK", dr["VAT_CHK"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_VAT", string.IsNullOrEmpty(dr["VAT"].ToString()) ? DBNull.Value : dr["VAT"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_UNIT", dr["UNIT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_SU_HYUN", dr["SU_HYUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_SPEC", dr["SPEC"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[7] = oDBManager.GetOraclePrameter("AS_SEQ_NO", dr["SEQ_NO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[8] = oDBManager.GetOraclePrameter("AS_REMARK", dr["REMARK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[9] = oDBManager.GetOraclePrameter("AS_REMAINDER", string.IsNullOrEmpty(dr["REMAINDER"].ToString()) ? DBNull.Value : dr["REMAINDER"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[10] = oDBManager.GetOraclePrameter("AS_PROOF", string.IsNullOrEmpty(dr["PROOF"].ToString()) ? DBNull.Value : dr["PROOF"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[11] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[12] = oDBManager.GetOraclePrameter("AS_PAYMENT", string.IsNullOrEmpty(dr["PAYMENT"].ToString()) ? DBNull.Value : dr["PAYMENT"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[13] = oDBManager.GetOraclePrameter("AS_INPUT", dr["INPUT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[14] = oDBManager.GetOraclePrameter("AS_FOOD_E", dr["FOOD_E"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[15] = oDBManager.GetOraclePrameter("AS_FOOD_D", dr["FOOD_D"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[16] = oDBManager.GetOraclePrameter("AS_FOOD_C", dr["FOOD_C"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[17] = oDBManager.GetOraclePrameter("AS_FOOD_B", dr["FOOD_B"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[18] = oDBManager.GetOraclePrameter("AS_FOOD_A", dr["FOOD_A"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[19] = oDBManager.GetOraclePrameter("AS_EQUIP_KIND", string.IsNullOrEmpty(dr["EQUIP_KIND"].ToString()) ? DBNull.Value : dr["EQUIP_KIND"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[20] = oDBManager.GetOraclePrameter("AS_EQUIP_CD", string.IsNullOrEmpty(dr["EQUIP_CD"].ToString()) ? DBNull.Value : dr["EQUIP_CD"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[21] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[22] = oDBManager.GetOraclePrameter("AS_COST", dr["COST"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[23] = oDBManager.GetOraclePrameter("AS_BIZ_REGNO", dr["BIZ_REGNO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[24] = oDBManager.GetOraclePrameter("AS_BIGO", dr["BIGO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[25] = oDBManager.GetOraclePrameter("AS_ATTACH", dr["ATTACH"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[26] = oDBManager.GetOraclePrameter("AS_ACCUM", string.IsNullOrEmpty(dr["ACCUM"].ToString()) ? DBNull.Value : dr["ACCUM"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);


                    nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD230T_U", oIDataParameter);
                }

            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }
    #endregion

    #region == 장비현황 DELETE(Procedure : SP_D_FPD230T_D ) ==

    /// <summary>
    /// 장비현황 DELETE
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 장비현황 DELETE(Procedure : SP_D_FPD230T_D )")]
    public int DELETE_D_FPD230T_D(DataSet pDs)
    {
        int nResult = 0;

        if (pDs == null || pDs.Tables[0].Rows.Count == 0)
            throw new Exception("저장할 데이터가 없습니다.");

        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                foreach (DataRow dr in pDs.Tables[0].Rows)
                {
                    System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                    oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_SEQ_NO", dr["AS_SEQ_NO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["AS_PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_DT", dr["AS_DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD230T_D", oIDataParameter);
                }

            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }
    #endregion

    #region == 장비현황 SAVE(Procedure : SP_D_FPD230T_U,SP_D_FPD230T_I,SP_D_FPD230T_D ) ==

    /// <summary>
    /// 장비현황 INSERT,UPDATE,DELETE
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 장비현황 SAVE(INSER,UPDATE,DELETE)(Procedure : SP_D_FPD230T_U,SP_D_FPD230T_I,SP_D_FPD230T_D )")]
    public int SAVE_D_FPD230T_IUD(DataSet pDs)
    {
        int nResult = 0;

        if (pDs == null || pDs.Tables[0].Rows.Count == 0)
            throw new Exception("저장할 데이터가 없습니다.");

        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                foreach (DataRow dr in pDs.Tables[0].Rows)
                {
                    if (dr.Table.Columns.Contains("Deleted_Id") && dr["Deleted_Id"].ToString().Equals("0"))
                    {
                        System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                        oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_SEQ_NO", dr["SEQ_NO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD230T_D", oIDataParameter);
                    }
                    else if (dr.Table.Columns.Contains("Created_Id") && dr["Created_Id"].ToString().Equals("0"))
                    {
                        System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[27];
                        oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_ZIP_OFFICE", dr["ZIP_OFFICE"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_ZIP_HYUN", dr["ZIP_HYUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_VAT_CHK", dr["VAT_CHK"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_VAT", string.IsNullOrEmpty(dr["VAT"].ToString()) ? DBNull.Value : dr["VAT"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_UNIT", dr["UNIT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_SU_HYUN", dr["SU_HYUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_SPEC", dr["SPEC"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[7] = oDBManager.GetOraclePrameter("AS_SEQ_NO", dr["SEQ_NO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[8] = oDBManager.GetOraclePrameter("AS_REMARK", dr["REMARK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[9] = oDBManager.GetOraclePrameter("AS_REMAINDER", string.IsNullOrEmpty(dr["REMAINDER"].ToString()) ? DBNull.Value : dr["REMAINDER"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[10] = oDBManager.GetOraclePrameter("AS_PROOF", string.IsNullOrEmpty(dr["PROOF"].ToString()) ? DBNull.Value : dr["PROOF"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[11] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[12] = oDBManager.GetOraclePrameter("AS_PAYMENT", string.IsNullOrEmpty(dr["PAYMENT"].ToString()) ? DBNull.Value : dr["PAYMENT"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[13] = oDBManager.GetOraclePrameter("AS_INPUT", dr["INPUT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[14] = oDBManager.GetOraclePrameter("AS_FOOD_E", dr["FOOD_E"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[15] = oDBManager.GetOraclePrameter("AS_FOOD_D", dr["FOOD_D"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[16] = oDBManager.GetOraclePrameter("AS_FOOD_C", dr["FOOD_C"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[17] = oDBManager.GetOraclePrameter("AS_FOOD_B", dr["FOOD_B"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[18] = oDBManager.GetOraclePrameter("AS_FOOD_A", dr["FOOD_A"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[19] = oDBManager.GetOraclePrameter("AS_EQUIP_KIND", string.IsNullOrEmpty(dr["EQUIP_KIND"].ToString()) ? DBNull.Value : dr["EQUIP_KIND"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[20] = oDBManager.GetOraclePrameter("AS_EQUIP_CD", string.IsNullOrEmpty(dr["EQUIP_CD"].ToString()) ? DBNull.Value : dr["EQUIP_CD"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[21] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[22] = oDBManager.GetOraclePrameter("AS_COST", dr["COST"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[23] = oDBManager.GetOraclePrameter("AS_BIZ_REGNO", dr["BIZ_REGNO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[24] = oDBManager.GetOraclePrameter("AS_BIGO", dr["BIGO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[25] = oDBManager.GetOraclePrameter("AS_ATTACH", dr["ATTACH"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[26] = oDBManager.GetOraclePrameter("AS_ACCUM", string.IsNullOrEmpty(dr["ACCUM"].ToString()) ? DBNull.Value : dr["ACCUM"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD230T_I", oIDataParameter);
                    }
                    else
                    {
                        System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[27];
                        oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_ZIP_OFFICE", dr["ZIP_OFFICE"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_ZIP_HYUN", dr["ZIP_HYUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_VAT_CHK", dr["VAT_CHK"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_VAT", string.IsNullOrEmpty(dr["VAT"].ToString()) ? DBNull.Value : dr["VAT"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_UNIT", dr["UNIT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_SU_HYUN", dr["SU_HYUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_SPEC", dr["SPEC"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[7] = oDBManager.GetOraclePrameter("AS_SEQ_NO", dr["SEQ_NO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[8] = oDBManager.GetOraclePrameter("AS_REMARK", dr["REMARK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[9] = oDBManager.GetOraclePrameter("AS_REMAINDER", string.IsNullOrEmpty(dr["REMAINDER"].ToString()) ? DBNull.Value : dr["REMAINDER"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[10] = oDBManager.GetOraclePrameter("AS_PROOF", string.IsNullOrEmpty(dr["PROOF"].ToString()) ? DBNull.Value : dr["PROOF"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[11] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[12] = oDBManager.GetOraclePrameter("AS_PAYMENT", string.IsNullOrEmpty(dr["PAYMENT"].ToString()) ? DBNull.Value : dr["PAYMENT"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[13] = oDBManager.GetOraclePrameter("AS_INPUT", dr["INPUT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[14] = oDBManager.GetOraclePrameter("AS_FOOD_E", dr["FOOD_E"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[15] = oDBManager.GetOraclePrameter("AS_FOOD_D", dr["FOOD_D"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[16] = oDBManager.GetOraclePrameter("AS_FOOD_C", dr["FOOD_C"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[17] = oDBManager.GetOraclePrameter("AS_FOOD_B", dr["FOOD_B"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[18] = oDBManager.GetOraclePrameter("AS_FOOD_A", dr["FOOD_A"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[19] = oDBManager.GetOraclePrameter("AS_EQUIP_KIND", string.IsNullOrEmpty(dr["EQUIP_KIND"].ToString()) ? DBNull.Value : dr["EQUIP_KIND"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[20] = oDBManager.GetOraclePrameter("AS_EQUIP_CD", string.IsNullOrEmpty(dr["EQUIP_CD"].ToString()) ? DBNull.Value : dr["EQUIP_CD"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[21] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[22] = oDBManager.GetOraclePrameter("AS_COST", dr["COST"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[23] = oDBManager.GetOraclePrameter("AS_BIZ_REGNO", dr["BIZ_REGNO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[24] = oDBManager.GetOraclePrameter("AS_BIGO", dr["BIGO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[25] = oDBManager.GetOraclePrameter("AS_ATTACH", dr["ATTACH"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[26] = oDBManager.GetOraclePrameter("AS_ACCUM", string.IsNullOrEmpty(dr["ACCUM"].ToString()) ? DBNull.Value : dr["ACCUM"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD230T_U", oIDataParameter);
                    }
                }

            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }
    #endregion


    #region == 공종계획 조회 ==

    /// <summary>
    /// 공종계획 조회
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "공종계획조회(PROJ_CD,DT,AS_ITEM_NM)")]
    public string Select_D_FPD210T_1_S(string pAS_PROJ_CD, string pAS_DT, string pAS_ITEM)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[5];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pAS_PROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", pAS_DT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_ITEM_NM", pAS_ITEM, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_RECORDSET2", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD210T_1_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }
    #endregion

    #region == 공종계획 UPDATE(Procedure : SP_D_FPD210T_1_U ) ==

    /// <summary>
    /// 공종계획 UPDATE
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 공종계획 UPDATE(Procedure : SP_D_FPD210T_1_U )")]
    public int UPDATE_D_FPD210T_1_U(DataSet pDs)
    {
        int nResult = 0;

        if (pDs == null || pDs.Tables[0].Rows.Count == 0)
            throw new Exception("저장할 데이터가 없습니다.");

        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                foreach (DataRow dr in pDs.Tables[0].Rows)
                {
                    System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[23];
                    oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_QTY", dr["QTY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_P_QTY", dr["P_QTY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_S_QTY", dr["S_QTY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_UC", dr["UC"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_AMT", dr["AMT"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_P_AMT", dr["P_AMT"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_S_AMT", dr["S_AMT"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[7] = oDBManager.GetOraclePrameter("AS_A_QTY", dr["A_QTY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[8] = oDBManager.GetOraclePrameter("AS_PROOF", string.IsNullOrEmpty(dr["PROOF"].ToString()) ? DBNull.Value : dr["PROOF"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[9] = oDBManager.GetOraclePrameter("AS_ITEM_CD", dr["ITEM_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[10] = oDBManager.GetOraclePrameter("AS_SUB_ITEM_CD", dr["SUB_ITEM_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[11] = oDBManager.GetOraclePrameter("AS_BIZ_REGNO", dr["BIZ_REGNO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[12] = oDBManager.GetOraclePrameter("AS_VAT_CHK", dr["VAT_CHK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[13] = oDBManager.GetOraclePrameter("AS_ATTACH", dr["ATTACH"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[14] = oDBManager.GetOraclePrameter("AS_SEQ_NO", dr["SEQ_NO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[15] = oDBManager.GetOraclePrameter("AS_REMARK", dr["REMARK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[16] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[17] = oDBManager.GetOraclePrameter("AS_UNIT", dr["UNIT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[18] = oDBManager.GetOraclePrameter("AS_ITEM_GUBUN", dr["ITEM_GUBUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[19] = oDBManager.GetOraclePrameter("AS_ITEM_CD_NM", dr["ITEM_CD_NM"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[20] = oDBManager.GetOraclePrameter("AS_SUB_ITEM_NM", dr["SUB_ITEM_NM"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[21] = oDBManager.GetOraclePrameter("AS_SPEC", dr["SPEC"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[22] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);

                    nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD210T_1_U", oIDataParameter);
                }

            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }
    #endregion

    #region == 공종계획 SAVE(Procedure : SP_D_FPD210T_1_U ) ==

    /// <summary>
    /// 장비현황 INSERT,UPDATE,DELETE
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 공종계획 SAVE(Procedure : SP_D_FPD210T_1_U )")]
    public int SAVE_D_FPD210T_1_IUD(DataSet pDs)
    {
        int nResult = 0;

        if (pDs == null || pDs.Tables[0].Rows.Count == 0)
            throw new Exception("저장할 데이터가 없습니다.");

        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                foreach (DataRow dr in pDs.Tables[0].Rows)
                {
                    if (dr.Table.Columns.Contains("Deleted_Id") && dr["Deleted_Id"].ToString().Equals("0"))
                    {
                        // DELETE 시
                    }
                    else if (dr.Table.Columns.Contains("Created_Id") && dr["Created_Id"].ToString().Equals("0"))
                    {
                        //INSERT 시
                        
                    }
                    else
                    {
                        System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[23];
                        oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_QTY", dr["QTY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_P_QTY", dr["P_QTY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_S_QTY", dr["S_QTY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_UC", dr["UC"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_AMT", dr["AMT"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_P_AMT", dr["P_AMT"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_S_AMT", dr["S_AMT"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[7] = oDBManager.GetOraclePrameter("AS_A_QTY", dr["A_QTY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[8] = oDBManager.GetOraclePrameter("AS_PROOF", string.IsNullOrEmpty(dr["PROOF"].ToString()) ? DBNull.Value : dr["PROOF"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[9] = oDBManager.GetOraclePrameter("AS_ITEM_CD", dr["ITEM_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[10] = oDBManager.GetOraclePrameter("AS_SUB_ITEM_CD", dr["SUB_ITEM_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[11] = oDBManager.GetOraclePrameter("AS_BIZ_REGNO", dr["BIZ_REGNO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[12] = oDBManager.GetOraclePrameter("AS_VAT_CHK", dr["VAT_CHK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[13] = oDBManager.GetOraclePrameter("AS_ATTACH", dr["ATTACH"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[14] = oDBManager.GetOraclePrameter("AS_SEQ_NO", dr["SEQ_NO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[15] = oDBManager.GetOraclePrameter("AS_REMARK", dr["REMARK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[16] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[17] = oDBManager.GetOraclePrameter("AS_UNIT", dr["UNIT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[18] = oDBManager.GetOraclePrameter("AS_ITEM_GUBUN", dr["ITEM_GUBUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[19] = oDBManager.GetOraclePrameter("AS_ITEM_CD_NM", dr["ITEM_CD_NM"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[20] = oDBManager.GetOraclePrameter("AS_SUB_ITEM_NM", dr["SUB_ITEM_NM"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[21] = oDBManager.GetOraclePrameter("AS_SPEC", dr["SPEC"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[22] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);

                        nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD210T_1_U", oIDataParameter);
                    }
                }

            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }
    #endregion



    #region == 운송현황 조회 ==

    /// <summary>
    /// 운송현황 조회
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "운송현황조회(PROJ_CD,DT)")]
    public string Select_DAYTRANSPORT1_S(string pAS_PROJ_CD, string pAS_DT)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pAS_PROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", pAS_DT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_DAYTRANSPORT1_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }
    #endregion

    #region == 운송현황 - 팝업 조회 ==
    /// <summary>
    /// 운송현황 - 팝업 조회 - 운송현황리스트(업체리스트)
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pCOMP_NM"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "운송현황 - 팝업 조회 - 운송현황리스트(CUST)(PROJ_CD,COMP_NM)")]
    public string Select_D_DAYWRITE_POP5_B_CUST_S(string pPROJ_CD, string pCOMP_NM)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pPROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_COMP_NM", pCOMP_NM, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_DAYWRITE_POP5_B_CUST_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }


    /// <summary>
    /// 운송현황 - 팝업 조회 - 운송현황리스트(아이템)
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pBIZ_REGNO"></param>
    /// <param name="pNAME"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "운송현황 - 팝업 조회 - 운송현황리스트(ITEM)(PROJ_CD,BIZ_REGNO,NAME)")]
    public string Select_D_DAYWRITE_POP5_B_ITEM_S(string pPROJ_CD, string pBIZ_REGNO, string pNAME)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[4];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pPROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_BIZ_REGNO", pBIZ_REGNO, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_NAME", pNAME, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_DAYWRITE_POP5_B_ITEM_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }
    //운송현황코드리스트는 장비현황 코드리스트와 동일한듯
    #endregion

    #region == 운송현황 INSERT(Procedure : SP_DAYTRANSPORT1_I ) ==

    /// <summary>
    /// 운송현황 INSERT
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 운송현황 INSERT(Procedure : SP_DAYTRANSPORT1_I )")]
    public int INSERT_DAYTRANSPORT1_I(DataSet pDs)
    {
        int nResult = 0;

        if (pDs == null || pDs.Tables[0].Rows.Count == 0)
            throw new Exception("저장할 데이터가 없습니다.");

        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                foreach (DataRow dr in pDs.Tables[0].Rows)
                {
                    System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[26];
                    oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_ZIP_OFFICE", dr["ZIP_OFFICE"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_ZIP_HYUN", dr["ZIP_HYUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_VAT_CHK", dr["VAT_CHK"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_VAT", dr["VAT"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_SU_OFFICE", dr["SU_OFFICE"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_SU_HYUN", dr["SU_HYUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_STDCOUNT", dr["STDCOUNT"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[7] = oDBManager.GetOraclePrameter("AS_START_LOC", dr["START_LOC"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[8] = oDBManager.GetOraclePrameter("AS_STANDARD", dr["STANDARD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[9] = oDBManager.GetOraclePrameter("AS_SEQ_NO", dr["SEQ_NO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[10] = oDBManager.GetOraclePrameter("AS_REMARK", dr["REMARK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[11] = oDBManager.GetOraclePrameter("AS_REMAINDER", dr["REMAINDER"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[12] = oDBManager.GetOraclePrameter("AS_PROOF", string.IsNullOrEmpty(dr["PROOF"].ToString()) ? DBNull.Value : dr["PROOF"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[13] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[14] = oDBManager.GetOraclePrameter("AS_PAY", dr["PAY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[15] = oDBManager.GetOraclePrameter("AS_NAME2", dr["NAME2"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[16] = oDBManager.GetOraclePrameter("AS_NAME", dr["NAME"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[17] = oDBManager.GetOraclePrameter("AS_INPUT", dr["INPUT"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[18] = oDBManager.GetOraclePrameter("AS_EQUIP_KIND", dr["EQUIP_KIND"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[19] = oDBManager.GetOraclePrameter("AS_EQUIP_CD", dr["EQUIP_CD"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[20] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[21] = oDBManager.GetOraclePrameter("AS_DEST_LOC", dr["DEST_LOC"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[22] = oDBManager.GetOraclePrameter("AS_CAR_NUM", dr["CAR_NUM"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[23] = oDBManager.GetOraclePrameter("AS_BIZ_REGNO", dr["BIZ_REGNO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[24] = oDBManager.GetOraclePrameter("AS_BIGO", dr["BIGO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[25] = oDBManager.GetOraclePrameter("AS_ATTACH", dr["ATTACH"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);

                    nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_DAYTRANSPORT1_I", oIDataParameter);
                }

            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }
    #endregion

    #region == 운송현황 UPDATE(Procedure : SP_DAYTRANSPORT1_U ) ==

    /// <summary>
    /// 운송현황 UPDATE
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 운송현황 UPDATE(Procedure : SP_DAYTRANSPORT1_U )")]
    public int UPDATE_DAYTRANSPORT1_U(DataSet pDs)
    {
        int nResult = 0;

        if (pDs == null || pDs.Tables[0].Rows.Count == 0)
            throw new Exception("저장할 데이터가 없습니다.");

        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                foreach (DataRow dr in pDs.Tables[0].Rows)
                {
                    System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[26];
                    oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_ZIP_OFFICE", dr["ZIP_OFFICE"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_ZIP_HYUN", dr["ZIP_HYUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_VAT_CHK", dr["VAT_CHK"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_VAT", dr["VAT"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_SU_OFFICE", dr["SU_OFFICE"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_SU_HYUN", dr["SU_HYUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_STDCOUNT", dr["STDCOUNT"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[7] = oDBManager.GetOraclePrameter("AS_START_LOC", dr["START_LOC"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[8] = oDBManager.GetOraclePrameter("AS_STANDARD", dr["STANDARD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[9] = oDBManager.GetOraclePrameter("AS_SEQ_NO", dr["SEQ_NO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[10] = oDBManager.GetOraclePrameter("AS_REMARK", dr["REMARK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[11] = oDBManager.GetOraclePrameter("AS_REMAINDER", dr["REMAINDER"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[12] = oDBManager.GetOraclePrameter("AS_PROOF", string.IsNullOrEmpty(dr["PROOF"].ToString()) ? DBNull.Value : dr["PROOF"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[13] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[14] = oDBManager.GetOraclePrameter("AS_PAY", dr["PAY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[15] = oDBManager.GetOraclePrameter("AS_NAME2", dr["NAME2"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[16] = oDBManager.GetOraclePrameter("AS_NAME", dr["NAME"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[17] = oDBManager.GetOraclePrameter("AS_INPUT", dr["INPUT"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[18] = oDBManager.GetOraclePrameter("AS_EQUIP_KIND", dr["EQUIP_KIND"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[19] = oDBManager.GetOraclePrameter("AS_EQUIP_CD", dr["EQUIP_CD"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[20] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[21] = oDBManager.GetOraclePrameter("AS_DEST_LOC", dr["DEST_LOC"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[22] = oDBManager.GetOraclePrameter("AS_CAR_NUM", dr["CAR_NUM"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[23] = oDBManager.GetOraclePrameter("AS_BIZ_REGNO", dr["BIZ_REGNO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[24] = oDBManager.GetOraclePrameter("AS_BIGO", dr["BIGO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[25] = oDBManager.GetOraclePrameter("AS_ATTACH", dr["ATTACH"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_DAYTRANSPORT1_U", oIDataParameter);
                }

            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }
    #endregion

    #region == 운송현황 DELETE(Procedure : SP_DAYTRANSPORT1_D ) ==

    /// <summary>
    /// 운송현황 DELETE
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 운송현황 DELETE(Procedure : SP_DAYTRANSPORT1_D )")]
    public int DELETE_DAYTRANSPORT1_D(DataSet pDs)
    {
        int nResult = 0;

        if (pDs == null || pDs.Tables[0].Rows.Count == 0)
            throw new Exception("저장할 데이터가 없습니다.");

        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                foreach (DataRow dr in pDs.Tables[0].Rows)
                {
                    System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                    oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_SEQ_NO", dr["SEQ_NO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_DAYTRANSPORT1_D", oIDataParameter);
                }

            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }
    #endregion

    #region == 운송현황 SAVE(Procedure : SP_DAYTRANSPORT1_I,SP_DAYTRANSPORT1_U,SP_DAYTRANSPORT1_D ) ==

    /// <summary>
    /// 운송현황 INSERT,UPDATE,DELETE
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 운송현황 SAVE(INSER,UPDATE,DELETE)(Procedure : SP_DAYTRANSPORT1_I,SP_DAYTRANSPORT1_U,SP_DAYTRANSPORT1_D )")]
    public int SAVE_DAYTRANSPORT1_IUD(DataSet pDs)
    {
        int nResult = 0;

        if (pDs == null || pDs.Tables[0].Rows.Count == 0)
            throw new Exception("저장할 데이터가 없습니다.");

        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                foreach (DataRow dr in pDs.Tables[0].Rows)
                {
                    if (dr.Table.Columns.Contains("Deleted_Id") && dr["Deleted_Id"].ToString().Equals("0"))
                    {
                        System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                        oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_SEQ_NO", dr["SEQ_NO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_DAYTRANSPORT1_D", oIDataParameter);
                    }
                    else if (dr.Table.Columns.Contains("Created_Id") && dr["Created_Id"].ToString().Equals("0"))
                    {
                        System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[26];
                        oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_ZIP_OFFICE", dr["ZIP_OFFICE"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_ZIP_HYUN", dr["ZIP_HYUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_VAT_CHK", dr["VAT_CHK"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_VAT", dr["VAT"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_SU_OFFICE", dr["SU_OFFICE"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_SU_HYUN", dr["SU_HYUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_STDCOUNT", dr["STDCOUNT"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[7] = oDBManager.GetOraclePrameter("AS_START_LOC", dr["START_LOC"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[8] = oDBManager.GetOraclePrameter("AS_STANDARD", dr["STANDARD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[9] = oDBManager.GetOraclePrameter("AS_SEQ_NO", dr["SEQ_NO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[10] = oDBManager.GetOraclePrameter("AS_REMARK", dr["REMARK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[11] = oDBManager.GetOraclePrameter("AS_REMAINDER", dr["REMAINDER"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[12] = oDBManager.GetOraclePrameter("AS_PROOF", string.IsNullOrEmpty(dr["PROOF"].ToString()) ? DBNull.Value : dr["PROOF"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[13] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[14] = oDBManager.GetOraclePrameter("AS_PAY", dr["PAY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[15] = oDBManager.GetOraclePrameter("AS_NAME2", dr["NAME2"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[16] = oDBManager.GetOraclePrameter("AS_NAME", dr["NAME"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[17] = oDBManager.GetOraclePrameter("AS_INPUT", dr["INPUT"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[18] = oDBManager.GetOraclePrameter("AS_EQUIP_KIND", dr["EQUIP_KIND"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[19] = oDBManager.GetOraclePrameter("AS_EQUIP_CD", dr["EQUIP_CD"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[20] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[21] = oDBManager.GetOraclePrameter("AS_DEST_LOC", dr["DEST_LOC"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[22] = oDBManager.GetOraclePrameter("AS_CAR_NUM", dr["CAR_NUM"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[23] = oDBManager.GetOraclePrameter("AS_BIZ_REGNO", dr["BIZ_REGNO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[24] = oDBManager.GetOraclePrameter("AS_BIGO", dr["BIGO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[25] = oDBManager.GetOraclePrameter("AS_ATTACH", dr["ATTACH"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);

                        nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_DAYTRANSPORT1_I", oIDataParameter);
                    }
                    else
                    {
                        System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[26];
                        oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_ZIP_OFFICE", dr["ZIP_OFFICE"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_ZIP_HYUN", dr["ZIP_HYUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_VAT_CHK", dr["VAT_CHK"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_VAT", dr["VAT"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_SU_OFFICE", dr["SU_OFFICE"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_SU_HYUN", dr["SU_HYUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_STDCOUNT", dr["STDCOUNT"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[7] = oDBManager.GetOraclePrameter("AS_START_LOC", dr["START_LOC"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[8] = oDBManager.GetOraclePrameter("AS_STANDARD", dr["STANDARD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[9] = oDBManager.GetOraclePrameter("AS_SEQ_NO", dr["SEQ_NO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[10] = oDBManager.GetOraclePrameter("AS_REMARK", dr["REMARK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[11] = oDBManager.GetOraclePrameter("AS_REMAINDER", dr["REMAINDER"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[12] = oDBManager.GetOraclePrameter("AS_PROOF", string.IsNullOrEmpty(dr["PROOF"].ToString()) ? DBNull.Value : dr["PROOF"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[13] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[14] = oDBManager.GetOraclePrameter("AS_PAY", dr["PAY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[15] = oDBManager.GetOraclePrameter("AS_NAME2", dr["NAME2"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[16] = oDBManager.GetOraclePrameter("AS_NAME", dr["NAME"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[17] = oDBManager.GetOraclePrameter("AS_INPUT", dr["INPUT"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[18] = oDBManager.GetOraclePrameter("AS_EQUIP_KIND", dr["EQUIP_KIND"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[19] = oDBManager.GetOraclePrameter("AS_EQUIP_CD", dr["EQUIP_CD"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[20] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[21] = oDBManager.GetOraclePrameter("AS_DEST_LOC", dr["DEST_LOC"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[22] = oDBManager.GetOraclePrameter("AS_CAR_NUM", dr["CAR_NUM"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[23] = oDBManager.GetOraclePrameter("AS_BIZ_REGNO", dr["BIZ_REGNO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[24] = oDBManager.GetOraclePrameter("AS_BIGO", dr["BIGO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[25] = oDBManager.GetOraclePrameter("AS_ATTACH", dr["ATTACH"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);

                        nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_DAYTRANSPORT1_U", oIDataParameter);
                    }
                }

            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }
    #endregion




    #region == 경비현황 조회 ==

    /// <summary>
    /// 경비현황 조회
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "경비현황조회(PROJ_CD,DT)")]
    public string Select_D_DAYEATPAY_S(string pAS_PROJ_CD, string pAS_DT)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pAS_PROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", pAS_DT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_DAYEATPAY_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }


    /// <summary>
    /// 경비현황 조회2
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "경비현황조회2(PROJ_CD,DT)")]
    public string Select_D_DAYEATPAY_S2(string pAS_PROJ_CD, string pAS_DT)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pAS_PROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", pAS_DT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_DAYEATPAY_S2", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }

    /// <summary>
    /// 경비현황 조회3
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "경비현황조회3(PROJ_CD,DT)")]
    public string Select_D_DAYEATPAY_S3(string pAS_PROJ_CD, string pAS_DT)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pAS_PROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", pAS_DT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_DAYEATPAY_S3", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }

    #endregion

    #region == 경비현황 - 팝업 조회 ==
    /// <summary>
    /// 경비현황 - 팝업 조회 - 경비현황리스트(대분류)
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pCOMP_NM"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "경비현황 - 팝업 조회 - 경비현황리스트(NUDE,CODE2)")]
    public string Select_SP_D_GYOUNGBI_S(int pNUDE, string pCODE2)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_NUDE", pNUDE, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_CODE2", pCODE2, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_GYOUNGBI_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }


    /// <summary>
    /// 경비현황 - 팝업 조회 - 경비현황리스트(소분류)
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pBIZ_REGNO"></param>
    /// <param name="pNAME"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "경비현황 - 팝업 조회 - 경비현황리스트(소분류)(NUDE,KIND, CODE2)")]
    public string Select_D_GYOUNGBI_SMALL_S(int pNUDE, int pKIND, string pCODE2)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[4];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_NUDE", pNUDE, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_KIND", pKIND, System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_CODE2", pCODE2, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_GYOUNGBI_SMALL_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }
    //전도금,법인카드 같은 팝업
    #endregion

    #region == 경비현황 - 경비코드관리 - 대분류입력(Procedure : SP_D_GYOUNGBI_I ) ==

    /// <summary>
    /// 경비현황 - 경비코드관리 - 대분류 INSERT
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 경비현황 - 경비코드관리 - 대분류 INSERT(Procedure : SP_D_GYOUNGBI_I )")]
    public int INSERT_D_GYOUNGBI_I(DataSet pDs)
    {
        int nResult = 0;

        if (pDs == null || pDs.Tables[0].Rows.Count == 0)
            throw new Exception("저장할 데이터가 없습니다.");

        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                foreach (DataRow dr in pDs.Tables[0].Rows)
                {
                    System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[4];

                    oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_NUDE", dr["NUDE"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_CODE", dr["CODE"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_NAME", dr["NAME"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_CODE2", dr["CODE2"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);

                    nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_GYOUNGBI_I", oIDataParameter);
                }

            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }
    #endregion

    #region == 경비현황 - 경비코드관리 - 대분류업데이트(Procedure : SP_D_GYOUNGBI_U ) ==

    /// <summary>
    /// 경비현황 - 경비코드관리 - 대분류 UPDATE
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 경비현황 - 경비코드관리 - 대분류 UPDATE(Procedure : SP_D_GYOUNGBI_U )")]
    public int UPDATE_D_GYOUNGBI_U(DataSet pDs)
    {
        int nResult = 0;

        if (pDs == null || pDs.Tables[0].Rows.Count == 0)
            throw new Exception("저장할 데이터가 없습니다.");

        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                foreach (DataRow dr in pDs.Tables[0].Rows)
                {
                    System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[4];

                    oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_NUDE", dr["NUDE"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_KIND", dr["KIND"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_NAME", dr["NAME"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_CODE2", dr["CODE2"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);

                    nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_GYOUNGBI_U", oIDataParameter);
                }

            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }
    #endregion

    #region == 경비현황 - 경비코드관리 DELETE(Procedure : SP_D_GYOUNGBI_D ) ==

    /// <summary>
    /// 경비현황 - 경비코드관리 DELETE
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 경비현황 - 경비코드관리 DELETE(Procedure : SP_D_GYOUNGBI_D )")]
    public int DELETE_D_GYOUNGBI_D(DataSet pDs)
    {
        int nResult = 0;

        if (pDs == null || pDs.Tables[0].Rows.Count == 0)
            throw new Exception("저장할 데이터가 없습니다.");

        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                foreach (DataRow dr in pDs.Tables[0].Rows)
                {
                    System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];

                    oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_NUDE", dr["NUDE"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_KIND", dr["KIND"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_CODE", dr["CODE"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);

                    nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_GYOUNGBI_D", oIDataParameter);
                }

            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }
    #endregion

    #region == 경비현황 - 경비코드관리 - 소분류입력(Procedure : SP_D_GYOUNGBI_SMALL_I ) ==

    /// <summary>
    /// 경비현황 - 경비코드관리 - 소분류 INSERT
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 경비현황 - 경비코드관리 - 소분류 INSERT(Procedure : SP_D_GYOUNGBI_SMALL_I )")]
    public int INSERT_D_GYOUNGBI_SMALL_I(DataSet pDs)
    {
        int nResult = 0;

        if (pDs == null || pDs.Tables[0].Rows.Count == 0)
            throw new Exception("저장할 데이터가 없습니다.");

        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                foreach (DataRow dr in pDs.Tables[0].Rows)
                {
                    System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[5];

                    oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_NUDE", dr["NUDE"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_KIND", dr["KIND"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_CODE", dr["CODE"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_NAME", dr["NAME"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_CODE2", dr["CODE2"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);

                    nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_GYOUNGBI_SMALL_I", oIDataParameter);
                }

            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }
    #endregion

    #region == 경비현황 - 경비코드관리 - 소분류업데이트(Procedure : SP_D_GYOUNGBI_SMALL_U ) ==

    /// <summary>
    /// 경비현황 - 경비코드관리 - 소분류 UPDATE
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 경비현황 - 경비코드관리 - 소분류 UPDATE(Procedure : SP_D_GYOUNGBI_SMALL_U )")]
    public int UPDATE_D_GYOUNGBI_SMALL_U(DataSet pDs)
    {
        int nResult = 0;

        if (pDs == null || pDs.Tables[0].Rows.Count == 0)
            throw new Exception("저장할 데이터가 없습니다.");

        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                foreach (DataRow dr in pDs.Tables[0].Rows)
                {
                    System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[4];

                    oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_NUDE", dr["NUDE"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_KIND", dr["KIND"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_CODE", dr["CODE"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_NAME", dr["NAME"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);

                    nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_GYOUNGBI_SMALL_U", oIDataParameter);
                }

            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }
    #endregion

    #region == 경비현황 INSERT(Procedure : SP_D_DAYEATPAY_I ) ==

    /// <summary>
    /// 장비현황 INSERT
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 경비현황 INSERT(Procedure : SP_D_DAYEATPAY_I )")]
    public int INSERT_D_DAYEATPAY_I(DataSet pDs)
    {
        int nResult = 0;

        if (pDs == null || pDs.Tables[0].Rows.Count == 0)
            throw new Exception("저장할 데이터가 없습니다.");

        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                foreach (DataRow dr in pDs.Tables[0].Rows)
                {
                    System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[21];

                    oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_ZIP_HYUN", dr["ZIP_HYUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_VAT_CHK", dr["VAT_CHK"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_SU_OFFICE", dr["SU_OFFICE"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_SU_HYUN", dr["SU_HYUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_SEQ_NO", dr["SEQ_NO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_RULE", dr["RULE"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_REMARK", dr["REMARK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[7] = oDBManager.GetOraclePrameter("AS_REMAINDER", dr["REMAINDER"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[8] = oDBManager.GetOraclePrameter("AS_PROOF", string.IsNullOrEmpty(dr["PROOF"].ToString()) ? DBNull.Value : dr["PROOF"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[9] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[10] = oDBManager.GetOraclePrameter("AS_PAY", dr["PAY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[11] = oDBManager.GetOraclePrameter("AS_PART", dr["PART"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[12] = oDBManager.GetOraclePrameter("AS_NKIND", dr["NKIND"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[13] = oDBManager.GetOraclePrameter("AS_NCODE", dr["NCODE"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[14] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[15] = oDBManager.GetOraclePrameter("AS_COUNT", dr["COUNT"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[16] = oDBManager.GetOraclePrameter("AS_BIZ_REGNO", dr["BIZ_REGNO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[17] = oDBManager.GetOraclePrameter("AS_BIZ_NAME", dr["BIZ_NAME"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[18] = oDBManager.GetOraclePrameter("AS_BIGO", dr["BIGO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[19] = oDBManager.GetOraclePrameter("AS_ATTACH", dr["ATTACH"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[20] = oDBManager.GetOraclePrameter("AS_ZIP_OFFICE", dr["ZIP_OFFICE"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);

                    nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_DAYEATPAY_I", oIDataParameter);
                }

            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }
    #endregion

    #region == 경비현황 UPDATE(Procedure : SP_D_DAYEATPAY_U ) ==

    /// <summary>
    /// 경비현황 UPDATE
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 경비현황 UPDATE(Procedure : SP_D_DAYEATPAY_U )")]
    public int UPDATE_D_DAYEATPAY_U(DataSet pDs)
    {
        int nResult = 0;

        if (pDs == null || pDs.Tables[0].Rows.Count == 0)
            throw new Exception("저장할 데이터가 없습니다.");

        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                foreach (DataRow dr in pDs.Tables[0].Rows)
                {
                    System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[21];

                    oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_ZIP_HYUN", dr["ZIP_HYUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_VAT_CHK", dr["VAT_CHK"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_SU_OFFICE", dr["SU_OFFICE"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_SU_HYUN", dr["SU_HYUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_SEQ_NO", dr["SEQ_NO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_RULE", dr["RULE"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_REMARK", dr["REMARK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[7] = oDBManager.GetOraclePrameter("AS_REMAINDER", dr["REMAINDER"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[8] = oDBManager.GetOraclePrameter("AS_PROOF", string.IsNullOrEmpty(dr["PROOF"].ToString()) ? DBNull.Value : dr["PROOF"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[9] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[10] = oDBManager.GetOraclePrameter("AS_PAY", dr["PAY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[11] = oDBManager.GetOraclePrameter("AS_PART", dr["PART"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[12] = oDBManager.GetOraclePrameter("AS_NKIND", dr["NKIND"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[13] = oDBManager.GetOraclePrameter("AS_NCODE", dr["NCODE"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[14] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[15] = oDBManager.GetOraclePrameter("AS_COUNT", dr["COUNT"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                    oIDataParameter[16] = oDBManager.GetOraclePrameter("AS_BIZ_REGNO", dr["BIZ_REGNO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[17] = oDBManager.GetOraclePrameter("AS_BIZ_NAME", dr["BIZ_NAME"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[18] = oDBManager.GetOraclePrameter("AS_BIGO", dr["BIGO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[19] = oDBManager.GetOraclePrameter("AS_ATTACH", dr["ATTACH"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[20] = oDBManager.GetOraclePrameter("AS_ZIP_OFFICE", dr["ZIP_OFFICE"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);

                    nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_DAYEATPAY_U", oIDataParameter);
                }

            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }
    #endregion

    #region == 경비현황 DELETE(Procedure : SP_D_DAYEATPAY_D ) ==

    /// <summary>
    /// 경비현황 DELETE
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 경비현황 DELETE(Procedure : SP_D_DAYEATPAY_D )")]
    public int DELETE_D_DAYEATPAY_D(DataSet pDs)
    {
        int nResult = 0;

        if (pDs == null || pDs.Tables[0].Rows.Count == 0)
            throw new Exception("저장할 데이터가 없습니다.");

        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                foreach (DataRow dr in pDs.Tables[0].Rows)
                {
                    System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                    oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_SEQ_NO", dr["SEQ_NO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                    nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_DAYEATPAY_D", oIDataParameter);
                }

            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }
    #endregion

    #region == 경비현황 SAVE(Procedure : SP_D_DAYEATPAY_I,SP_D_DAYEATPAY_U,SP_D_DAYEATPAY_D ) ==

    /// <summary>
    /// 경비현황 INSERT,UPDATE,DELETE
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Required, Description = " 경비현황 SAVE(INSER,UPDATE,DELETE)(Procedure : SP_DAYTRANSPORT1_I,SP_DAYTRANSPORT1_U,SP_DAYTRANSPORT1_D )")]
    public int SAVE_D_DAYEATPAY_IUD(DataSet pDs)
    {
        int nResult = 0;

        if (pDs == null || pDs.Tables[0].Rows.Count == 0)
            throw new Exception("저장할 데이터가 없습니다.");

        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                foreach (DataRow dr in pDs.Tables[0].Rows)
                {
                    if (dr.Table.Columns.Contains("Deleted_Id") && dr["Deleted_Id"].ToString().Equals("0"))
                    {
                        System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                        oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_SEQ_NO", dr["SEQ_NO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_DAYEATPAY_D", oIDataParameter);
                    }
                    else if (dr.Table.Columns.Contains("Created_Id") && dr["Created_Id"].ToString().Equals("0"))
                    {
                        System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[21];

                        oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_ZIP_HYUN", dr["ZIP_HYUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_VAT_CHK", dr["VAT_CHK"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_SU_OFFICE", dr["SU_OFFICE"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_SU_HYUN", dr["SU_HYUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_SEQ_NO", dr["SEQ_NO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_RULE", dr["RULE"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_REMARK", dr["REMARK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[7] = oDBManager.GetOraclePrameter("AS_REMAINDER", dr["REMAINDER"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[8] = oDBManager.GetOraclePrameter("AS_PROOF", string.IsNullOrEmpty(dr["PROOF"].ToString()) ? DBNull.Value : dr["PROOF"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[9] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[10] = oDBManager.GetOraclePrameter("AS_PAY", dr["PAY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[11] = oDBManager.GetOraclePrameter("AS_PART", dr["PART"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[12] = oDBManager.GetOraclePrameter("AS_NKIND", dr["NKIND"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[13] = oDBManager.GetOraclePrameter("AS_NCODE", dr["NCODE"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[14] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[15] = oDBManager.GetOraclePrameter("AS_COUNT", dr["COUNT"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[16] = oDBManager.GetOraclePrameter("AS_BIZ_REGNO", dr["BIZ_REGNO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[17] = oDBManager.GetOraclePrameter("AS_BIZ_NAME", dr["BIZ_NAME"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[18] = oDBManager.GetOraclePrameter("AS_BIGO", dr["BIGO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[19] = oDBManager.GetOraclePrameter("AS_ATTACH", dr["ATTACH"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[20] = oDBManager.GetOraclePrameter("AS_ZIP_OFFICE", dr["ZIP_OFFICE"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);

                        nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_DAYEATPAY_I", oIDataParameter);
                    }
                    else
                    {
                        System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[21];

                        oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_ZIP_HYUN", dr["ZIP_HYUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_VAT_CHK", dr["VAT_CHK"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_SU_OFFICE", dr["SU_OFFICE"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_SU_HYUN", dr["SU_HYUN"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_SEQ_NO", dr["SEQ_NO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_RULE", dr["RULE"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[6] = oDBManager.GetOraclePrameter("AS_REMARK", dr["REMARK"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[7] = oDBManager.GetOraclePrameter("AS_REMAINDER", dr["REMAINDER"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[8] = oDBManager.GetOraclePrameter("AS_PROOF", string.IsNullOrEmpty(dr["PROOF"].ToString()) ? DBNull.Value : dr["PROOF"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[9] = oDBManager.GetOraclePrameter("AS_PROJ_CD", dr["PROJ_CD"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[10] = oDBManager.GetOraclePrameter("AS_PAY", dr["PAY"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[11] = oDBManager.GetOraclePrameter("AS_PART", dr["PART"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[12] = oDBManager.GetOraclePrameter("AS_NKIND", dr["NKIND"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[13] = oDBManager.GetOraclePrameter("AS_NCODE", dr["NCODE"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[14] = oDBManager.GetOraclePrameter("AS_DT", dr["DT"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[15] = oDBManager.GetOraclePrameter("AS_COUNT", dr["COUNT"], System.Data.OracleClient.OracleType.Number, ParameterDirection.Input);
                        oIDataParameter[16] = oDBManager.GetOraclePrameter("AS_BIZ_REGNO", dr["BIZ_REGNO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[17] = oDBManager.GetOraclePrameter("AS_BIZ_NAME", dr["BIZ_NAME"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[18] = oDBManager.GetOraclePrameter("AS_BIGO", dr["BIGO"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[19] = oDBManager.GetOraclePrameter("AS_ATTACH", dr["ATTACH"].ToString().Equals("true") ? 1 : 0, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                        oIDataParameter[20] = oDBManager.GetOraclePrameter("AS_ZIP_OFFICE", dr["ZIP_OFFICE"], System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);

                        nResult = oDBManager.Execute(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_DAYEATPAY_U", oIDataParameter);
                    }
                }

            }

        }
        catch (Exception pException)
        {
            throw pException;
        }

        return nResult;
    }
    #endregion




    #region == 외주관리 마스터 조회 ==

    /// <summary>
    /// 외주관리 마스터 조회
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "외주관리 마스터 조회(PROJ_CD,DT)")]
    public string Select_D_FPD370T_S(string pAS_PROJ_CD, string pAS_DT)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pAS_PROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", pAS_DT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD370T_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }
    #endregion

    #region == 외주관리 디테일 조회 ==

    /// <summary>
    /// 외주관리 디테일 조회
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "외주관리 디테일 조회(PROJ_CD,DT)")]
    public string Select_D_FPD370T_DETAIL_S(string pAS_PROJ_CD, string pAS_DT,string pSeqNo)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[4];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pAS_PROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", pAS_DT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_SEQ_NO", pSeqNo, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD370T_DETAIL_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }
    #endregion

    #region == Compression ==

    public string CompressDataSet(DataSet ds)
    {
        

        //1. 데이터셋 Serialize
        ds.RemotingFormat = SerializationFormat.Binary;
        BinaryFormatter bf = new BinaryFormatter();
        MemoryStream ms = new MemoryStream();
        bf.Serialize(ms, ds);
        byte[] inbyt = ms.ToArray();

        //2. 데이터 압축
        System.IO.MemoryStream objStream = new MemoryStream();
        System.IO.Compression.DeflateStream objZS = new System.IO.Compression.DeflateStream(objStream, System.IO.Compression.CompressionMode.Compress);
        objZS.Write(inbyt, 0, inbyt.Length);
        objZS.Flush();
        objZS.Close();
        //3. 데이터 리턴
        byte[] data =  objStream.ToArray();

        return Convert.ToBase64String(data, 0, data.Length);
    }

    #endregion


    #region == 인원현황 조회 ==

    /// <summary>
    /// 인원현황 조회
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    private DataSet Select_FPD220T_P_c(string pAS_PROJ_CD, string pAS_DT)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pAS_PROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", pAS_DT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_FPD220T_P", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return dsReturn;
    }
    #endregion

    #region == 주자재현황 조회 ==
    /// <summary>
    /// 주자재현황 조회
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    private DataSet Select_FPD240T_P_c(string pAS_PROJ_CD, string pAS_DT)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pAS_PROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", pAS_DT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_FPD240T_P", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return dsReturn;
    }
    #endregion

    #region == 장비현황 조회 ==

    /// <summary>
    /// 장비현황 조회
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    private DataSet Select_D_FPD230T_S_c(string pAS_PROJ_CD, string pAS_DT)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pAS_PROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", pAS_DT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD230T_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return dsReturn;
    }
    #endregion

    #region == 공종계획 조회 ==

    /// <summary>
    /// 공종계획 조회
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    private DataSet Select_D_FPD210T_1_S_c(string pAS_PROJ_CD, string pAS_DT, string pAS_ITEM)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[5];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pAS_PROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", pAS_DT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_ITEM_NM", pAS_ITEM, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_RECORDSET2", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD210T_1_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return dsReturn;
    }
    #endregion

    #region == 운송현황 조회 ==

    /// <summary>
    /// 운송현황 조회
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    private DataSet Select_DAYTRANSPORT1_S_c(string pAS_PROJ_CD, string pAS_DT)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pAS_PROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", pAS_DT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_DAYTRANSPORT1_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return dsReturn;
    }
    #endregion

    #region == 경비현황 조회 ==

    /// <summary>
    /// 경비현황 조회
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    private DataSet Select_D_DAYEATPAY_S_c(string pAS_PROJ_CD, string pAS_DT)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pAS_PROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", pAS_DT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_DAYEATPAY_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return dsReturn;
    }
    #endregion

    #region == 외주관리 마스터 조회 ==

    /// <summary>
    /// 외주관리 마스터 조회
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    private DataSet Select_D_FPD370T_S_c(string pAS_PROJ_CD, string pAS_DT)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[3];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pAS_PROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", pAS_DT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD370T_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return dsReturn;
    }
    #endregion

    #region == 외주관리 디테일 조회 ==

    /// <summary>
    /// 외주관리 디테일 조회
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <returns></returns>
    private DataSet Select_D_FPD370T_DETAIL_S_c(string pAS_PROJ_CD, string pAS_DT, string pSeqNo)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[4];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pAS_PROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", pAS_DT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_SEQ_NO", pSeqNo, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_FPD370T_DETAIL_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return dsReturn;
    }
    #endregion

    #region 외주관리 - 외주관리팝업 - 주요자재현황
    /// <summary>
    /// 외주관리 - 외주관리팝업 - 주요자재현황
    /// </summary>
    /// <param name="pAS_PROJ_CD"></param>
    /// <param name="pAS_DT"></param>
    /// <param name="pBIZ_REGNO"></param>
    /// <param name="pSUB_ITEM_NM"></param>
    /// <param name="pSPEC"></param>
    /// <returns></returns>
    [WebMethod(TransactionOption = TransactionOption.Supported, Description = "외주관리팝업-주요자재현황(PROJ_CD,DT,BIZ_REGNO,SUB_ITEM_NM,SPEC)")]
    public string Select_D_DAYWRITE_POP8_1_S(string pAS_PROJ_CD, string pAS_DT, string pBIZ_REGNO, string pSUB_ITEM_NM, string pSPEC)
    {
        DataSet dsReturn = null;
        try
        {
            using (DBManager oDBManager = new DBManager())
            {
                System.Data.OracleClient.OracleParameter[] oIDataParameter = new OracleParameter[6];
                oIDataParameter[0] = oDBManager.GetOraclePrameter("AS_PROJ_CD", pAS_PROJ_CD, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[1] = oDBManager.GetOraclePrameter("AS_DT", pAS_DT, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[2] = oDBManager.GetOraclePrameter("AS_BIZ_REGNO", pBIZ_REGNO, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[3] = oDBManager.GetOraclePrameter("AS_SUB_ITEM_NM", pSUB_ITEM_NM, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[4] = oDBManager.GetOraclePrameter("AS_SPEC", pSPEC, System.Data.OracleClient.OracleType.VarChar, ParameterDirection.Input);
                oIDataParameter[5] = oDBManager.GetOraclePrameter("AS_RECORDSET", DBNull.Value, System.Data.OracleClient.OracleType.Cursor, ParameterDirection.Output);
                dsReturn = oDBManager.GetDataSet(CommandType.StoredProcedure, "EMDISBEST.BESTWEBPKG.SP_D_DAYWRITE_POP8_1_S", oIDataParameter);
            }
        }
        catch (Exception pException)
        {
            throw pException;
        }
        finally
        {
        }

        return this.CompressDataSet(dsReturn);
    }
    #endregion
}

